Skip to content

How to use @layer when migrate sass to Dart Sass 3.0.0 #15788

Answered by wongjn
Viktoria-ol asked this question in Help
Discussion options

You must be logged in to vote

From sass/sass#3240 (comment):

I'm not a huge fan of this, since we're generally trying to encourage users to move away from writing a bunch of files that all directly emit CSS and towards exposing mixins that the entrypoint can compose as it chooses. In this case, you can already effectively model most of this behavior using meta.load-css():

@use 'sass:meta';

@layer reset {
  @include meta.load-css('reset');
}

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@Viktoria-ol
Comment options

@wongjn
Comment options

wongjn Jan 24, 2025
Collaborator

Answer selected by Viktoria-ol
@Viktoria-ol
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
2 participants