catc / react-timekeeper

Google Keep app inspired time picker for react :clock4:
https://catc.github.io/react-timekeeper
MIT License
696 stars 67 forks source link

Support for React 17 #75

Closed joeyparis closed 2 years ago

joeyparis commented 3 years ago

Attempting to use react-timekeeper with React 17 leads to a styling error from @emotion/core. Upgrading from emotion 10 to emotion 11 (by proxy switching from @emotion/core to @emotion/react) appears to solve this issue. However, that causes tests to fail (despite everything appearing to still work) as enzyme still only supports up to React 16.

There are a few options: we can use the unofficial enzyme-adapter-react-17, we can use a different testing library, or we can ignore the failed tests until Enzyme officially supports React 17, which seems like might be relatively soon.

I'm happy to create a pull request for any of these options!

catc commented 2 years ago

Bumped react peer deps to v17 (see https://github.com/catc/react-timekeeper/commit/11a2c00af05582d5d5256c26a8eb025057597950#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519R77-R79). Can you check if this is still causing issues? May need to change emotion lib too.

catc commented 2 years ago

Also updated emotion to v11 so this should be fixed.

joeyparis commented 2 years ago

All seems to be working! Thanks for this and the other recent updates :)