1

I have been building my application on web pack and testing using web pack. My biggest concerned is how can deploy it after the application is complete?

Do i need to use the 'Webpack' dev server for production or just deploy direct my 'dist' folder to production.

2

1 Answer 1

4

No, you should not use webpack dev server on prod, and it's particularly said in docs. Yes, you should make a build with webpack, probably using another config (or having conditions in your config, e.g. depending on ENV variables). For example, you would probably want to run minifiers, or hash your files for cache busting. And then you just upload dist to your webserver (if you don't use any CI tools of course, in that case you should run a build there) and run apache, nginx or anything else there.

Sign up to request clarification or add additional context in comments.

1 Comment

This was so helpful. Thanks

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.