applyTheme
applyTheme(
element,theme): () =>void
Defined in: theme.ts:52
Write tokens onto an element.
Returns a function restoring the previous values, so a component that unmounts mid-stream does not leave a half-applied theme behind on a long-lived host element.
Parameters
Section titled “Parameters”element
Section titled “element”HTMLElement
ResolvedTheme | null
Returns
Section titled “Returns”() => void