I am building my first private, local (Atmosphere) package with the ES6
import syntax instead of
addFiles(). I am following the instructions of the Meteor Guide, which tells me to set my my
mainModule and then import other files or components from that module.
However, when I try to import a local file located in the package folder
routes/home.js from within
server.js like this:
the server crashes with this error message:
Error: Can't find npm module 'routes/home'. Did you forget to call 'Npm.depends' in package.js within the 'modules-runtime' package?
I found some similar posts here, but they all referred to imports from npm modules like
react, in my case it’s just a package-local file. I have included the
ecmascript package in my package.js, but this doesn’t help. Is there something else I am missing?