L
L
littleguga2016-06-27 19:28:52
Software Deployment
littleguga, 2016-06-27 19:28:52

How to properly use node_modules in production?

I use gulp and some of its plugins to build the project, they are installed as dev deps.
As normal dependencies, material-design-lite from google and jquery are installed. And so I thought about how to connect them correctly in the final project?
I have a dist/ folder in the web face of the site, in which the collected html, css, js, pictures already lie.
Put node_modules inside or copy (it is clear that not with pens, but with gulp) to the dist folder from node_modules?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
F
fso, 2016-06-27
@littleguga

Collect from node_modules into one file (scripts and styles separately), minify, place the result in doc_root.
You can collect several files, according to functionality, and connect them in batches as needed.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question