Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/css loader #13

Merged
merged 29 commits into from
Feb 20, 2024
Merged

Feature/css loader #13

merged 29 commits into from
Feb 20, 2024

Conversation

gwleuverink
Copy link
Owner

@gwleuverink gwleuverink commented Feb 13, 2024

This PR adds a basic CSS loader that should cover most use cases (needs lightningcss as a dependency)

Sass is also supported, but needs to be installed separately

  • update docs
  • import .css files
  • import .scss files
  • support css imports
  • support minification
  • support browser targeting
  • supports CSS sourcemaps
  • supports Sass sourcemaps
  • automatically injects css into the DOM
  • add tests for css loading (scss, css & assert dom)
  • add tests for config options (minify & etc)
  • check for missing dependencies (only when needed) and throw appropriate exceptions (needs to be reworked in separate PR)
  • Improve docs (Explain Bun's auto install feature - module resolution algorithm)

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 97% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Copy link

codecov bot commented Feb 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (fdccec9) 96.95% compared to head (47dae87) 97.02%.
Report is 5 commits behind head on main.

❗ Current head 47dae87 differs from pull request most recent head 9deb0ca. Consider uploading reports for the commit 9deb0ca to get more accurate results

Additional details and impacted files
@@             Coverage Diff              @@
##               main      #13      +/-   ##
============================================
+ Coverage     96.95%   97.02%   +0.07%     
- Complexity       42       43       +1     
============================================
  Files             6        6              
  Lines           197      202       +5     
============================================
+ Hits            191      196       +5     
  Misses            6        6              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 97% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 2 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 98% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 2 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 98% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 0 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 98% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 0 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 98% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 0 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 98% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 0 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 98% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 1 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 99% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Comment on lines +40 to +43
if (
gettype($output) === 'object' &&
property_exists($output, 'id') &&
property_exists($output, 'message') &&

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❌ New issue: Complex Conditional
BundlingFailedException.output has 1 complex conditionals with 3 branches, threshold = 2

Why does this problem occur?

A complex conditional is an expression inside a branch (e.g. if, for, while) which consists of multiple, logical operators such as AND/OR. The more logical operators in an expression, the more severe the code smell. Read more.

To ignore this warning click here.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will be reworked in a separate PR

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 1 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 99% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 1 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 99% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 1 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 99% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 1 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 99% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

@gwleuverink gwleuverink marked this pull request as ready for review February 20, 2024 17:05
Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 1 files(s) 🔥

Recommended Review Level: Detailed -- Increased risk for defects: The change involves more modules and modified lines of code than 99% of the historic high-risk change sets. The risk is lower since it is an experienced author responsible for 99% of all commits in this repo.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

@gwleuverink gwleuverink merged commit 4171887 into main Feb 20, 2024
7 checks passed
@gwleuverink gwleuverink deleted the feature/css-loader branch August 25, 2024 00:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant