Skip to content

Commit

Permalink
chore(select): added exhaustive-deps ignore comments
Browse files Browse the repository at this point in the history
  • Loading branch information
anuraghazra committed Nov 17, 2020
1 parent bf476e2 commit a8acc78
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/select/Select.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ export const useSelect = createHook<SelectOptions, SelectHTMLProps>({
const action = keyMap[event.key as keyof typeof keyMap];
action?.();
},
// eslint-disable-next-line react-hooks/exhaustive-deps
[
options.visible,
options.show,
Expand Down
1 change: 1 addition & 0 deletions src/select/SelectBaseState.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable react-hooks/exhaustive-deps */
import * as React from "react";
import { SetState } from "reakit-utils/ts";
import { CompositeStateReturn, CompositeState, CompositeActions } from "reakit";
Expand Down
1 change: 1 addition & 0 deletions src/select/SelectItem.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable react-hooks/exhaustive-deps */
import {
CompositeItemOptions,
CompositeItemHTMLProps,
Expand Down
1 change: 1 addition & 0 deletions src/select/stories/SelectControlled.component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ const SelectComp: React.FC<SelectCompProps> = props => {

React.useEffect(() => {
if (!isUndefined(value)) select.setSelectedValue(value);
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [select.setSelectedValue, value]);

React.useEffect(() => {
Expand Down
1 change: 1 addition & 0 deletions src/select/stories/SelectWindows.component.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ export const App: React.FC<SelectInitialState> = props => {
const action = keyMap[event.key as keyof typeof keyMap];
if (action) action();
},
// eslint-disable-next-line react-hooks/exhaustive-deps
[
select.values,
select.visible,
Expand Down

0 comments on commit a8acc78

Please sign in to comment.