Mixins / foldkit-mixins/theme

schemeScript

function · packages/mixins/src/theme/scheme.ts:24

function schemeScript(key?: string): string

The text of a <script> for the document's head, before any stylesheet draws: it applies the scheme kept under key, so a reader who chose dark never sees one light frame. Storage that throws (a private window) or holds anything else leaves the stylesheet's choice.