| Class | Description | |
|---|---|---|
will-changeSets will-change via --will-change. Hints the browser about upcoming changes. E.g. transform, opacity. CSS Rules Usage
The .will-change
class is flagged as a value-driven selector.
The variable --will-change is required. Responsive
Prefix
States
States are generated dynamically at runtime and always
come last. Append a state like
Supported pseudo-classes: Group Hover Example
The Pseudo-Elements
The Shorthand
Value-driven classes support a shorthand syntax like CLS Alert
This feature may cause CLS (Cumulative Layout
Shift). Make sure to include a
| .will-change | Sets will-change via --will-change. Hints the browser about upcoming changes. E.g. transform, opacity. |
will-change-autoLets the browser decide whether to apply will-change optimizations. CSS Rules Usage Responsive
Prefix
States
States are generated dynamically at runtime and always
come last. Append a state like
Supported pseudo-classes: Group Hover Example
The Pseudo-Elements
The | .will-change-auto | Lets the browser decide whether to apply will-change optimizations. |
will-change-scrollHints that scroll position will change, helping the browser optimize scrolling. CSS Rules Usage Responsive
Prefix
States
States are generated dynamically at runtime and always
come last. Append a state like
Supported pseudo-classes: Group Hover Example
The Pseudo-Elements
The | .will-change-scroll | Hints that scroll position will change, helping the browser optimize scrolling. |
will-change-contentsHints that element content will change, helping the browser optimize rendering. CSS Rules Usage Responsive
Prefix
States
States are generated dynamically at runtime and always
come last. Append a state like
Supported pseudo-classes: Group Hover Example
The Pseudo-Elements
The | .will-change-contents | Hints that element content will change, helping the browser optimize rendering. |
will-change-transformHints that transforms will change, helping the browser optimize compositing. CSS Rules Usage Responsive
Prefix
States
States are generated dynamically at runtime and always
come last. Append a state like
Supported pseudo-classes: Group Hover Example
The Pseudo-Elements
The | .will-change-transform | Hints that transforms will change, helping the browser optimize compositing. |