Some of the packages such as jQuery, moment.js are capable working on both client and server version, some even provide 2 different versions, one for client, one for server,
so you can definitely do
npm install jquery and include them from your
node_modules folder like how you would normally include your script.
You could also take a look at these,
PS: If they have a client-side, it could also be available on Bower, the "client-side" npm.
PS2: If you would like to "require" libraries like you do on node, you could try to use AMD RequireJS as well. It provides similar syntax as CommonJS
if you're using npm packages on views better switch to bower because npm is not made for inclusion on views. It will work on some but some packages will not work like that.
Sign in to participate in this thread!
We'd like to thank these amazing companies for supporting us