https://github.com/chantastic/react-aria-dropdown
WIP
https://github.com/chantastic/react-aria-dropdown
Last synced: 12 months ago
JSON representation
WIP
- Host: GitHub
- URL: https://github.com/chantastic/react-aria-dropdown
- Owner: chantastic
- License: mit
- Created: 2018-08-14T05:55:38.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-08-14T06:35:16.000Z (almost 8 years ago)
- Last Synced: 2025-06-16T12:04:51.458Z (about 1 year ago)
- Size: 28.3 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# react-aria-dropdown
## Installation
### Node
```bash
npm i react-aria-dropdown
```
### Browser
```bash
```
## Usage
### Codesandbox
https://codesandbox.io/s/98l4pm0v4o
### Import
Import used for examples below:
```js
import {
Provider as Dropdown,
Consumer,
ToggleButton,
Popup
} from "react-aria-dropdown";
```
### Basic
```jsx
popup content}>
Toggle
```
### Basic + id
```jsx
popup content}>
Toggle
```
### Basic + initialState
```jsx
popup content}
>
Toggle
```
### Optional render-prop
```jsx
popup content}>
{context => (
{JSON.stringify(context.state, null, 2)}
)}
```
### Optional Context Consumer
```jsx
popup content}>
{context => (
{JSON.stringify(context.state, null, 2)}
)}
```
### License
MIT
Copyright © Michael Chan, 2018