react-popper
react-popper copied to clipboard
fix: flow type fixes for popper-core 2.3.3
This PR is based on https://github.com/popperjs/react-popper/pull/352
I have a problem with the following error though π€
Error βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ src/usePopper.js:95:37
Cannot call React.useMemo with function bound to create because string [1] is incompatible with string literal
updateState [2] in property name of array element of property modifiers of the return value.
[2] 27β type UpdateStateModifier = Modifier<'updateState', {||}>;
:
[1] 90β { name: 'applyStyles', enabled: false },
91β ],
92β };
93β
94β if (isEqual(prevOptions.current, newOptions)) {
95β return prevOptions.current || newOptions;
96β } else {
97β prevOptions.current = newOptions;
98β return newOptions;