Re: [csswg-drafts] [css-conditional-4] Rename @when to @if (#6684)

One of the options for Sass is introducing a new Sass-specific block at-rule like `@sass`. Inside that rule, rules such as `@if` would behave as Sass-specific rules.

All substylesheets imported inside `@sass` block would inherit that behavior, so updating and older Sass stylesheet for using a newer Sass version would be as simple as wrapping the stylesheet’s root-file contents with `@sass`:

```scss
@sass {
 // Inside the rule, `@if` behaves Sass-specific way
}

// Outside of the rule, `@if` behaves standard CSS way.
```

Additionally, a convenient way for using standard CSS `@if` inside `@sass` rules could optionally be provided, by using a prefix like `css-` or `standard-`:

```scss
@sass {
 // Inside the rule, `@if` behaves Sass-specific way

 @css-if {
  // Behaves as standard CSS `@if`.
 }
}

-- 
GitHub Notification of comment by Marat-Tanalin
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6684#issuecomment-1073070711 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Saturday, 19 March 2022 19:43:43 UTC