Skip to content

Silence sass errors #1674

New issue

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

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

Already on GitHub? # to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

MichalBryxi
Copy link

This finally silences:

[test:ember]
[test:ember]   ╷
[test:ember] 9 │ @import './tailwind/components/docs-btn';
[test:ember]   │         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[test:ember]   ╵
[test:ember]     addon/styles/addon.scss#sass 9:9  root stylesheet
[test:ember]
[test:ember] DEPRECATION WARNING: Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.

Fixes: #1673

It's not possible to migrate away from `@import` because:

```
pnpx sass-migrator module --migrate-deps addon/styles/addon.scss

...

Error: This stylesheet was loaded by a nested import in addon/styles/addon.scss. The module system only supports loading nested CSS using the load-css() mixin, which doesn't allow access to variables from the outer stylesheet.
  ╷
2 │   width: calc(((100% - #{$site-container}) / 2) + 14rem);
  │                          ^^^^^^^^^^^^^^^
  ╵
  addon/styles/components/_docs-viewer-x-current-page-index.scss 2:26  root stylesheet
```
This finally silences:

```
[test:ember]
[test:ember]   ╷
[test:ember] 9 │ @import './tailwind/components/docs-btn';
[test:ember]   │         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[test:ember]   ╵
[test:ember]     addon/styles/addon.scss#sass 9:9  root stylesheet
[test:ember]
[test:ember] DEPRECATION WARNING: Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.
```

Fixes: ember-learn#1673
@MichalBryxi MichalBryxi force-pushed the mb/1673-silence-sass-errors branch from 6d3449a to e0106bc Compare April 23, 2025 07:44
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Silence Sass import warnings
2 participants