nursery/useNamedLayer
nursery · since 2.5.9
No autofix
biome.json
{
"linter": {
"rules": {
"nursery": {
"useNamedLayer": "error"
}
}
}
}@layer {
a {
color: red;
}
}@import "theme.css" layer;@layer base {
a {
color: red;
}
}@import "theme.css" layer(base);Examples from the Biome documentation.
No tracked preset enables this rule, so it has no reach yet.
None of the tracked presets enable this rule. Turn it on with the config below.
ESLint does not have this rule.
Oxlint does not have this rule.
nursery/useNamedLayer
nursery · since 2.5.9
{
"linter": {
"rules": {
"nursery": {
"useNamedLayer": "error"
}
}
}
}Prefer logical CSS properties over physical properties.
Enforces the use of with { type: "json" } for JSON module imports.