-
-
Notifications
You must be signed in to change notification settings - Fork 514
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(examples): allow project node_modules to be used (#2200)
## Description The custom resolver implemented in our `metro.config.js` right now most likely does not conver all cases. When working on my PR with modals for Android I've added `jotai` package and received errors from bundler that this package is not found, because: 1. it was not present in any nearby `node_modules` - the file that requries it resides now in `apps/test-examples`, thus application `node_modules` are not checked by default, 2. only our custom resolver looks into apps `node_modules` & fails to resolve this package. I haven't investigated why it does not work for `jotai` in particular, because more general solution is to just let the default module resolution algorithm look into application `node_modules` as it should always do. ## Changes Added application `node_modules` to the list of additional node modules in metro config of each example application. ## Test code and steps to reproduce Install `jotai` w/o this change, require it in any example and try to run the application. Then apply changes from this PR and see it works well. ## Checklist - [ ] Ensured that CI passes
- Loading branch information
Showing
5 changed files
with
15 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters