I have a local node module I am trying to reuse in my other modules.
I use npm link to add the module as a dependency to other modules.
Everything works fine, however IntelliJ Treats this as an indirect dependency even if I add the dependency to the pom. Because of this none of the autocompletions for the dependency work.
Pom1:
{
"name": "test-module",
"version": "1.0.0",
"description": "\"Module functionality testing project\"",
"main": "index.js",
"scripts": {
"test": "\"No Tests done\""
},
"author": "",
"license": "ISC"
}
pom2:
{
"name": "test-module-2",
"version": "1.0.0",
"description": "\"Module functionality testing project\"",
"main": "index.js",
"scripts": {
"dev": "node index.js",
"test": "\"No Tests done\""
},
"author": "",
"license": "ISC",
"dependencies": {
"test-module": "^1.0.0"
}
}
Anyone know why this is and how to fix it?
The issue is tracked at WEB-49242, please follow it for updates.
As a workaround, please try including node_modules\test-module
folder in index by selecting Mark directory as/Cancel exclusion from its right-click menu