carrot / sprout

:seedling: simple project templating & skeletons
MIT License
86 stars 7 forks source link

Should use `npm i --production` when installing dependencies in a template #155

Closed jescalan closed 8 years ago

jescalan commented 8 years ago

Many of our templates now load up a few packages to run a test suite to ensure it compiles. In the case of sprout or roots templates, these are heavy dependencies and take a while to install, where they are not needed in order to actually use the template, resulting in a huge delay for no reason on the first time a user attempts to initialize a template.

On the other hand, it is necessary that we install dependencies when initializing a template, because in the init.js file, you can use dependencies to run transforms on the options etc.

So I think we should use the --production flag when installing template deps, to ensure that dev deps are not installed, which will save a bunch of time on template initializations 😁

kylemac commented 8 years ago

oh yeah - this is a great call. this may actually make a really big difference