I’m updating my app to Meteor 3. It uses ApolloGraphQL. I previously used swydo:ddp-apollo to interact with Apollo. But, swydo:ddp-apollo appears to require fibers. So, I’m following the Meteor create --apollo
sample app. I’ve duplicated all the relevant code from it to my app.
I’m having a little anomaly with imports.
The Meteor create --apollo
sample app includes this structure:
├── imports
│ ├── apollo
│ │ ├── resolvers.js
│ │ └── schema.graphql
├── server
│ ├── apollo.js
│ ├── init.js
│ └── synced-cron
│ ├── cron.js
│ └── main.js
└── settings.json
The file apollo.js
includes this line:
import typeDefs from '/imports/apollo/schema.graphql';
…and it runs as expected without error.
My app includes the same structure:
├── imports
│ ├── apollo
│ │ ├── resolvers.js
│ │ └── schema.graphql
├── server
│ ├── apollo.js
└── settings.json
The file apollo.js
includes this line:
import typeDefs from '/imports/apollo/schema.graphql';
When I run it, I get the error:
Cannot find module ‘/imports/apollo/schema.graphql’
…in apollo.js on that line.
What am I missing?