Mixins / foldkit-mixins/theme

chooseKnobs

function · packages/mixins/src/theme/knobsKept.ts:90

function chooseKnobs<S extends KnobSet>(
  theme: KnobTheme<S>,
  { base, key = KNOBS_KEY, selector = ':root' }: KnobsChoice<S>,
): Effect.Effect<void>

Applies theme's knobs to selector and keeps them under key for the next visit, as a Command's effect: the knobs that differ from base, so the base theme writes and keeps nothing. Storage that throws still applies them to this page.