docs: add useClickAway reference

This commit is contained in:
Va Da 2019-04-25 20:05:01 +02:00 committed by GitHub
parent f8c6252b44
commit f5e4cf6fe1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -24,3 +24,11 @@ const Demo = () => {
);
};
```
## Reference
```js
useClickAway(ref, onMouseEvent)
useClickAway(ref, onMouseEvent, ['click'])
useClickAway(ref, onMouseEvent, ['mousedown', 'touchstart'])
```