Skip to content

Commit

Permalink
Code review
Browse files Browse the repository at this point in the history
  • Loading branch information
jathak committed Oct 15, 2024
1 parent a894134 commit cc201a6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
4 changes: 2 additions & 2 deletions source/blog/043-import-is-deprecated.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ date: 2024-10-15 13:00:00 -8
Back in 2019, we [released the Sass module system], adding new `@use` and
`@forward` rules to the language that were designed to replace `@import` and
make stylesheets more maintainable and less error-prone. We can now announce
that `@import` is officially deprecated as of Dart Sass 1.78.0.
that `@import` is officially deprecated as of Dart Sass 1.80.0.

[released the Sass module system]: /blog/the-module-system-is-launched

Expand Down Expand Up @@ -40,7 +40,7 @@ treat any Sass `@import` rules as errors.
## Timeline

As previously announced, given the size of this change, we expect to wait at
least a year after this deprecation before we remove `@import` from the
least a two years after this deprecation before we remove `@import` from the
language. While we plan to release Dart Sass 2.0.0 soon with other, smaller
breaking changes, that release will not include any changes to `@import`.
Instead, we expect `@import` to be removed in Dart Sass 3.0.0.
Expand Down
11 changes: 5 additions & 6 deletions source/documentation/breaking-changes/import.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,10 @@ introduction: >
several years.
---

Sass historically loaded dependencies in a single global namespace using
`@import` rules. This causes numerous problems, requiring Sass members to be
manually namespaced to avoid conflicts, slowing down compilation when the same
file is imported more than once, and making it very difficult for both humans
and tools to tell where a given variable, mixin, or function comes from.
`@import` causes numerous problems, requiring Sass members to be manually
namespaced to avoid conflicts, slowing down compilation when the same file is
imported more than once, and making it very difficult for both humans and tools
to tell where a given variable, mixin, or function comes from.

The module system fixes these problems and brings Sass's modularity up to par
with the best practices of other modern languages, but we can't get the full
Expand All @@ -30,7 +29,7 @@ Sass `@import` rules and global built-in function calls now emit deprecation
warnings. While Dart Sass 2.0.0 will be released soon with various smaller
breaking changes, we don't expect to remove Sass `@import` rules or global
built-in functions until Dart Sass 3.0.0, which will be released no sooner than
a year after Dart Sass 1.80.0.
two years after Dart Sass 1.80.0.

Eventually, all `@import` rules will be treated as [plain CSS `@import`s],
likely after an intermediate period where anything that used to be a Sass
Expand Down

0 comments on commit cc201a6

Please sign in to comment.