Practic BUI (Base UI) - v1.0.0
    Preparing search index...

    Function SwitchWidget

    • Shows a labelled switch whose state can persist. The root's own props, such as disabled and name, pass through.

      Parameters

      • props: SwitchWidgetProps

        Switch props. children: Label beside the switch. initialValue: Whether it starts on until a state is stored; off by default. data-attr: Attribute the state persists under; without it, the state stays local. onCheckedChange: Called after each change is stored.

      Returns Element