npm / @radix-ui/react-switch
@radix-ui/react-switch
What changed in @radix-ui/react-switch 1, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-19.
3 new APIs and options1 performance1 tooling6 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli init@radix-ui/react-switch 111 changes
New APIs and options 3
Added the unstable BubbleInput part so consumers can directly access and recompose the hidden form input; Switch continues to render it by default.
Added the unstable Provider part so consumers can directly access and recompose the context provider; Switch continues to render it by default.
Added the unstable Trigger part so consumers can directly access and recompose the interactive control; Switch continues to render it by default.
Performance 1
Improved tree-shaking lets bundlers drop unused components.
Tooling 1
The package was republished through CI so it includes a provenance attestation; the code is unchanged.
Fixes and other changes 6
Fixed a type regression so callback props declared as methods accept handlers whose parameter is narrower than the prop's.
Fixed form-nested control components so user-driven changes are not treated as programmatic in some cases, allowing bubbled event handlers to be called.
Optional types now allow explicit undefined, making them compatible with TypeScript's exactOptionalPropertyTypes flag.
Reverted breaking changes that caused compatibility issues with React Server Components.
Programmatic value updates inside a form no longer dispatch a click event from the hidden bubble input that propagates to ancestor onClick handlers.
Switch values are now updated when their associated form is reset.