This project is read-only.

Loading custom modules in the Interactive Window

Aug 19, 2014 at 10:00 AM
Edited Aug 19, 2014 at 10:02 AM

The interactive window is a very nice feature. It's great that I'm able to test out NodeJS code on the fly.

I have a couple of questions:
  • Is it possible to associate the interactive window with a particular project in Visual Studio? This would permit loading custom modules defined in that project.
  • How do I load a module installed via npm? At present this works:
var x = require('fs');
but this doesn't
var x = require('htmlParser2')
Error: Cannot find module 'htmlParser2'
NB: I have installed htmlParser2 in one of the NTVS projects, but not all of them.
Aug 22, 2014 at 5:20 PM
This discussion has been copied to a work item. Click here to go to the work item and continue the discussion.
Aug 22, 2014 at 5:22 PM
Thanks for the suggestion. I remember we discussed this, but I can't find a work item for it, so I opened a new one.