I have files in a
/models/ directory off the root of the Meteor application. That directory is in
.meteorignore so it’s not automatically loaded.
I can’t do
import SomeModule from '/models/some-module.js' from a file in the
/imports/ directory. In
some-module.js, the error says that the
import (at the top of the
some-module.js file) is a Syntax Error.
In other words it is treating
/models/ directory different than
/imports/ directory. The same file in the
/imports/ directory will import fine.
Please, if anybody knows how to fix this without moving all the files into
/imports/ I would be grateful.