Closed KyleAsaff closed 4 years ago
Thanks for bringing this up.
I haven't yet tested the library with React Hooks so I'm not sure how/if it works. Thinking it would be better to have the timeout API exposed as hooks.
This is a good article on it by Dan Abramov:
https://overreacted.io/making-setinterval-declarative-with-react-hooks/
I am encountering the same issue using this - tho it seems to not do any harm - side note on that Dan Abramov article - I was using https://overreacted.io/making-setinterval-declarative-with-react-hooks/ hooks before using react-timeout instead as that hook got some weird race condition if used multiple times on different component at the same time.
This is the same as #119 - tracking changes there instead.
I'm getting a warning in my console output since changing my class based React component to a functional component (with React hooks).
This only occurs when I wrap my functional component in React with ReactTimeout
export default ReactTimeout(Tile);
The warning does not seem to break anything so I am wondering what is causing it and if it's non-breaking how to suppress it? I am not using Refs in my component.