@solid-aria/toggle
Version:
Primitives for building toggle components like checkboxes and switches.
44 lines (28 loc) • 1.66 kB
Markdown
<p>
<img width="100%" src="https://assets.solidjs.com/banner?type=Aria&background=tiles&project=Toggle" alt="Solid Aria - Toggle">
</p>
# @solid-aria/toggle
[](https://pnpm.io/)
[](https://turborepo.org/)
[](https://bundlephobia.com/package/@solid-aria/toggle)
[](https://www.npmjs.com/package/@solid-aria/toggle)
[](https://github.com/solidjs-community/solid-aria#contribution-process)
Primitives for building toggle components like checkboxes and switches.
## Installation
```bash
npm install @solid-aria/toggle
# or
yarn add @solid-aria/toggle
# or
pnpm add @solid-aria/toggle
```
## `createToggleState`
Provides state management for toggle components like checkboxes and switches.
### How to use it
See the docs of [createCheckbox](../checkbox) for an example of `createToggleState`.
## `createToggle`
Handles interactions for toggle elements, e.g. Checkboxes and Switches.
### How to use it
See the docs of [createCheckbox](../checkbox) for an example of `createToggle`.
## Changelog
All notable changes are described in the [CHANGELOG.md](./CHANGELOG.md) file.