Style
/ API ReferenceStyle
/ API ReferenceresponsiveValue
A function to cast a responsive array value to its expected type.
Important Note
This requires the responsiveValuePlugin to be configured.
The Gist
import { responsiveValue } from '@weser/style'
const style = responsiveValue(['blue', , 'red'])
Parameters
| Parameter | Type | Description |
|---|---|---|
| value | Array<T> | The responsive array value to cast. |
Returns
(T) The cast value.
© 2024-present Robin Weser. All Rights Reserved.