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

Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0 #374

Closed
dkniffin opened this issue Feb 10, 2025 · 3 comments
Closed

Comments

@dkniffin
Copy link
Contributor

I've recently switched my application over to use dart-sass, and I'm seeing this deprecation warning:

css             | Deprecation Warning [import]: Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.
css             |
css             | More info and automated migrator: https://sass-lang.com/d/import
css             |
css             |   ╷
css             | 3 │ @import 'tocbot-core';
css             |   │         ^^^^^^^^^^^^^
css             |   ╵
css             |     tocbot/src/scss/tocbot.scss 3:9                                  @use
css             |     app/assets/stylesheets/styles/5_pages/components_index.scss 1:1  @use
css             |     app/assets/stylesheets/styles/5_pages/_index.scss 83:1           @use
css             |     app/assets/stylesheets/5_pages.scss 9:1                          root stylesheet
css             |
css             | Deprecation Warning [import]: Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.
css             |
css             | More info and automated migrator: https://sass-lang.com/d/import
css             |
css             |   ╷
css             | 4 │ @import 'tocbot-default-theme';
css             |   │         ^^^^^^^^^^^^^^^^^^^^^^
css             |   ╵
css             |     tocbot/src/scss/tocbot.scss 4:9                                  @use
css             |     app/assets/stylesheets/styles/5_pages/components_index.scss 1:1  @use
css             |     app/assets/stylesheets/styles/5_pages/_index.scss 83:1           @use
css             |     app/assets/stylesheets/5_pages.scss 9:1                          root stylesheet
@tscanlin tscanlin mentioned this issue Feb 11, 2025
@tscanlin
Copy link
Owner

Hello again Derek, hope you are doing well!

I appreciate you letting me know about this deprecation warning. Here is a PR that upgrades sass and switches to @use instead of @import.
#375

I made a prerelease too for easier testing: [email protected]
Can you let me know if this prerelease/PR solves those warnings for you?
I believe it should. Thanks!

@tscanlin
Copy link
Owner

This should be fixed in 4.35.0. Thanks again for reporting!

@dkniffin
Copy link
Contributor Author

@tscanlin Thank you for jumping on this so quickly! Yes, it looks like that resolved the deprecation warnings. Thanks!

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

No branches or pull requests

2 participants