Skip to content

Commit 2b4325e

Browse files
authored
Merge pull request #284 from sparksuite/reduce-variables-in-examples
Reduce variables in examples
2 parents 9401baa + c8ae0d6 commit 2b4325e

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ import useDropdownMenu from 'react-accessible-dropdown-menu-hook';
3838
Call the Hook, telling it how many items your menu will have:
3939

4040
```tsx
41-
const { buttonProps, itemProps, isOpen, setIsOpen } = useDropdownMenu(numberOfItems);
41+
const { buttonProps, itemProps, isOpen } = useDropdownMenu(numberOfItems);
4242
```
4343

4444
Spread the `buttonProps` onto a button:

website/docs/design/options.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Option | Explanation
1313
`disableFocusFirstItemOnClick` | If specified as `true` the default behavior of focusing the first menu item on click will be disabled. The menu button will instead retain focus.
1414

1515
```js
16-
const { buttonProps, itemProps, isOpen, setIsOpen } = useDropdownMenu(numberOfItems, {
16+
useDropdownMenu(numberOfItems, {
1717
disableFocusFirstItemOnClick: true,
1818
});
1919
```

website/docs/getting-started/using.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ title: Using
55
To use the Hook, first call it, telling it how many items your menu will have:
66

77
```jsx
8-
const { buttonProps, itemProps, isOpen, setIsOpen } = useDropdownMenu(numberOfItems);
8+
const { buttonProps, itemProps, isOpen } = useDropdownMenu(numberOfItems);
99
```
1010

1111
Take the `buttonProps` object and spread it onto a button:

0 commit comments

Comments
 (0)