When attempting to import from the graphql-tools
package, the app crashes to the red error screen with the following message:
Unable to resolve module
graphql
from/path/to/project/node_modules/graphql-tools/dist/schemaGenerator.js
: Module does not exist in the module map
(N.B. The module path in the error can vary based on what you’re importing.)
It also mentions facebook/react-native#4968 but the seemingly accepted workaround steps do not appear to have any effect, plus it’s reproducible in a fresh project.
Reproduction steps:
- Create a new Expo project
- Add
graphql-tools
package to project - Try to import from it (e.g.
import { makeExecutableSchema } from 'graphql-tools';
)
Versions:
- Expo 25.0.0
- graphql-tools 2.19.0 (also tested previous version, 2.18.0)
Any advice? This should work, right? Thanks.