react-native-community / upgrade-helper

⚛️ A web tool to support React Native developers in upgrading their apps.
https://react-native-community.github.io/upgrade-helper
MIT License
3.67k stars 112 forks source link

Updated React to 18, testing-library to 14 #341

Closed CraigRamey closed 1 year ago

CraigRamey commented 1 year ago

Summary

Saw this tweet by Kelset and decided to take a few minutes to upgrade some deps.

Upgraded React to 18.2.0, and @testing-library/react to 14.

Test Plan

Tests pass, app still seems to work as it previously did.

image image image

Checklist

pvinis commented 1 year ago

oh, node error @testing-library/react@14.0.0: The engine "node" is incompatible with this module. Expected version ">=14". Got "10.24.1"

CraigRamey commented 1 year ago

The node version for the Netlify needs to be set to at least v14. It's on v10 right now. error @testing-library/react@14.0.0: The engine "node" is incompatible with this module. Expected version ">=14". Got "10.24.1"

pvinis commented 1 year ago

maybe we need to do this? https://www.elian.codes/blog/21-12-03-set-your-node-version-in-netlify/ @lucasbento. or maybe add me to the team on netlify?

flexbox commented 1 year ago

@pvinis normally you could do it with a simple .node-version file https://docs.netlify.com/configure-builds/manage-dependencies/#node-js-and-javascript

It will help everyone to be on the same page, instead of in 6 month "Oh I need to update this website but I have no idea what's the node version"

lucasbento commented 1 year ago

@pvinis setup on Netlify is quite odd and I can't add anyone else to the team without paying, unfortunately.

Would be great if it's possible to do by code like @flexbox suggested, I'll take a look tomorrow again to be sure that the team option is not available for OSS.

CraigRamey commented 1 year ago

@pvinis normally you could do it with a simple .node-version file https://docs.netlify.com/configure-builds/manage-dependencies/#node-js-and-javascript

It will help everyone to be on the same page, instead of in 6 month "Oh I need to update this website but I have no idea what's the node version"

Thanks for the advice. I've set the version of node to 16.19.1 and it seems to be fine now. Originally attempted to set it to the LTS version 18.14.2, and that ran into a different issue that would need to be addressed.

kelset commented 1 year ago

Thank you so much @CraigRamey! What's your twitter account? I want to make sure to celebrate your contribution proper 🎉

pvinis commented 1 year ago

I think it's https://twitter.com/theramey. thanks for the PR! 💜