Node.js core modules are not configured-Webstorm

So i have configured node.js core modules in project settings but i still keep on getting red swiggly in my javascript files for my node.js project. For all the other modules which are defined in my package.json file are fine as they are installed locally for that project in node_modules folder. But for core node library i dont get any intellisense as well as get red swiggly when i do

var fs = require('fs');

What am i missing. I have tried everything, wasted quite a bit of time, so try to ask on this forum if someone can please help me ?.

Thanks

4 comments

Ok, thanks solved it now. Had to set my node.js src path again in application_config.xml file.

0

Hi Net,

How did you configure Node.js core modules in project settings?
Technically if you configured it in a right way there should be created a JavaScript Library named "Node.js {version} Core Library".
When you get red error highlighting on a "require('fs');" statement please position caret on module name ('fs'), press Alt+Enter and select "Configure sources of Node.js core moudles".

More detailed explanation could be found here: http://blog.jetbrains.com/webide/2012/03/attaching-the-sources-of-node-js-core-modules/

--
Sergey

0

I'm not using nodejs.  SilkJS supports commonJS require.  When I require('fs'), the IDE shows an error.  It is not an error.

How do I turn off anything to do with NodeJS for a project that isn't NodeJS?

0

It's possible to disable Node.js plugin via Settings | Plugins.

0

Please sign in to leave a comment.