-
-
Notifications
You must be signed in to change notification settings - Fork 518
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refact: example apps file structure and ts support #2174
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, provided that it works (the apps do build and metro bundles) I think we are 🟢
Thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fine for me
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just test it with all caches cleared to be sure it works correctly 🎉
I've triggered CI again as e2e Android tests & iOS build on Fabric have failed. |
The failing CI check |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I think facing the fact that the tests do pass w/o issues in local env, I think we should not be blocked by our CI setup / just CI runners and proceed here.
We need to handle these CI issues somehow separately.
if (moduleName.startsWith('@react-navigation')) { | ||
// For some reason, react-navigation packages don't want to resolve from | ||
// the project's node_modules, so we need to use standard Metro resolver. | ||
return context.resolveRequest(context, moduleName, platform); | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why this has been removed? Were there any errors regarding resolving this module? I'm just curious 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
After deleting the package.json file from apps/examples
this code had to be deleted as the app couldn't find the react navigation packages
…2174) ## Description This PR intents to simplify example and test example apps file structure and fix typescript support. ## Changes - removed package.json inside common dir and adjusted metro config to work with those dependencies - relocated app.js file inside test examples common dir to match examples dir structure - added submodules paths to the root tsconfig and extended it in the example dirs <!-- ## Screenshots / GIFs Here you can add screenshots / GIFs documenting your change. You can add before / after section if you're changing some behavior. ### Before ### After --> ## Test code and steps to reproduce - Build and check wether the example and test example app works well on both paper and fabric architectures. - Have a look at the imports in any file inside apps/ directory and enjoy less red marks + full typescript support for linked packages! ## Checklist - [ ] Included code example that can be used to test this change - [ ] Updated TS types - [ ] Updated documentation: <!-- For adding new props to native-stack --> - [ ] https://github.com/software-mansion/react-native-screens/blob/main/guides/GUIDE_FOR_LIBRARY_AUTHORS.md - [ ] https://github.com/software-mansion/react-native-screens/blob/main/native-stack/README.md - [ ] https://github.com/software-mansion/react-native-screens/blob/main/src/types.tsx - [ ] https://github.com/software-mansion/react-native-screens/blob/main/src/native-stack/types.tsx - [ ] Ensured that CI passes
Description
This PR intents to simplify example and test example apps file structure and fix typescript support.
Changes
Test code and steps to reproduce
Checklist