Tuesday 29 December 2015

node_modules at root of all projects directory?

I've mostly been developing with Node but lately also been exploring Go. The convention there is to have a root directory where all dependencies live (src/ in your GOPATH -- see http://ift.tt/1JPeSr5)I'm curious if anyone has tried this approach with Node.. That is, if I were to have a root projects folder, e.g. /home/thukjeche/projects and in that a node_modules/ folder, any projects in that directory could use/would install module in that directory.Then each project's package.json can specify the version it needs.The main advantage I think this would give is install time (when using the same packages over and over again for different projects, I get quite tired of waiting for npm install to finish, especially for things related to babel).Glad to hear your thoughts

Submitted December 30, 2015 at 12:36AM by thukjeche

No comments:

Post a Comment