In #227, I accidentally made the minimum react-native dependency 0.73. Since the PR itself has no source code changes (only test app changes) that wasn't necessary. This PR brings the minimum back down to RN 0.57. I did this by:
Updating the rnx-kit configs to set development (and test app) to 0.73, while production to 0.57
Run yarn rnx-align-deps --write
Remove the rnx-kit configs altogether as they aren't actually necessary (more a tool to help with upgrades, and can be used without having a config in your package.json).
This does mean if someone came and ran npx @rnx-kit/align-deps@latest --requirements react-native@0.74 or something later, it would bump the minimum to 0.74 and not take into account the minimum. I figure nobody will do this, so safe to remove.
Also, from #230, I realized we were no longer auto linking RNCClipboard in our test app. This is due to autolinking not following yarn workspaces. We can fix this by adding the extra dependencies key to our react-native.config.js to help the react native CLI auto link the library.
Furthermore, after talking with @tido64 , I realized I had set up the test app a bit off. I had two package.json files: one at the root and one for the example app. With this approach, we would need two react native configs. A more common setup amongst RN community modules is to only have one package.json and react-native config. This meant some more refactoring to bring the test app in line with other repos, and ensure autolinking still worked with Yarn 4.
End result is a working modern test app :)
Test Plan
Test app boots and loads the module correctly on iOS.
Overview
In #227, I accidentally made the minimum react-native dependency
0.73
. Since the PR itself has no source code changes (only test app changes) that wasn't necessary. This PR brings the minimum back down to RN 0.57. I did this by:yarn rnx-align-deps --write
Remove the rnx-kit configs altogether as they aren't actually necessary (more a tool to help with upgrades, and can be used without having a config in your package.json).
npx @rnx-kit/align-deps@latest --requirements react-native@0.74
or something later, it would bump the minimum to 0.74 and not take into account the minimum. I figure nobody will do this, so safe to remove.Also, from #230, I realized we were no longer auto linking RNCClipboard in our test app. This is due to autolinking not following yarn workspaces. We can fix this by adding the extra
dependencies
key to ourreact-native.config.js
to help the react native CLI auto link the library.Furthermore, after talking with @tido64 , I realized I had set up the test app a bit off. I had two package.json files: one at the root and one for the example app. With this approach, we would need two react native configs. A more common setup amongst RN community modules is to only have one package.json and react-native config. This meant some more refactoring to bring the test app in line with other repos, and ensure autolinking still worked with Yarn 4.
End result is a working modern test app :)
Test Plan
Test app boots and loads the module correctly on iOS.