@supports
A CSS rule that applies styles only if the browser supports a given property, value or selector.
In more detail
@supports (grid-template-rows: subgrid) { ... } wraps the enhanced layout so browsers without subgrid ignore it and keep the fallback.
Related terms
- progressive enhancement — Building a page that works everywhere first, then adding better features for browsers that support them.
- fallback — A second choice used when the first is unavailable, such as a simpler layout for older browsers or a default value when a variable is missing.
Taught in
- CSS Subgrid: Inheriting Track Sizing Across Nested Layouts — Frontend Architecture & Web Platform