I'm getting errors on local modules.
Using the following to start my application:
"start": "NODE_PATH=\"$(pwd)\" node -r babel-register -r babel-polyfill src/index.js",
By setting NODE_PATH
to the root directory where package.json
lies enables me to write imports from the root:
import config from 'src/utils/config';
This is annoying the import/no-extraneous-dependencies
rule. If I write the relative path it doesn't complain. Is there a way for eslint
to recognize the root directory as the starting path for module import paths?