Skip to content

Commit

Permalink
fix: downshift content props already imports autocomplete props
Browse files Browse the repository at this point in the history
  • Loading branch information
AssisrMatheus committed Aug 23, 2022
1 parent a62f47b commit a24b9ff
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/components/AutocompleteInput/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -220,8 +220,7 @@ const DownshiftAutocompleteContent = <Item extends { id: string | number }>({
help,

...props
}: DownshiftAutocompleteContentProps<Item> &
Omit<React.InputHTMLAttributes<HTMLInputElement>, 'value' | 'defaultValue'>) => {
}: DownshiftAutocompleteContentProps<Item>) => {
// I use ref instead of state for this, because I don't want it to trigger an effect or re-render.
// I could simply not use it on the deps array, BUT then the value wouldn't be up to date inside the effect scope
const isFetchingRef = useRef(false);
Expand Down

0 comments on commit a24b9ff

Please sign in to comment.