https://github.com/neosiae/use-tabbable-list
React hook that returns all tabbable elements within a DOM node
https://github.com/neosiae/use-tabbable-list
Last synced: 3 months ago
JSON representation
React hook that returns all tabbable elements within a DOM node
- Host: GitHub
- URL: https://github.com/neosiae/use-tabbable-list
- Owner: neosiae
- License: mit
- Created: 2019-05-18T18:50:11.000Z (about 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-04T21:48:14.000Z (over 2 years ago)
- Last Synced: 2025-03-17T08:42:57.739Z (4 months ago)
- Language: JavaScript
- Size: 3.07 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 17
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# use-tabbable-list
 [](https://travis-ci.com/neosiae/use-tabbable-list)   [](https://github.com/prettier/prettier)
React hook that returns all tabbable elements within a DOM node
## Installation
> \$ npm install use-tabbable-list
## Usage
```javascript
import useTabbableList from 'use-tabbable-list'function Example() {
const ref = useRef(null)const tabbableList = useTabbableList(ref)
return (
Click!
)
}
```## API
### `useTabbableList(ref)`
#### ref
A reference to a DOM Node.
#### Return value
An array of all tabbable elements within the `ref` node.
## License
MIT