A
A
ar52016-05-12 16:11:55
css
ar5, 2016-05-12 16:11:55

Webpack, how many files to pack files into?

Friends, the question arose, how to properly collect project files? What is the good approach of collecting into a single bundle.js. How to deal with css styles?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Mikhail Osher, 2016-05-12
@miraage

In webpack, you can:
- set multiple entries -
extract common parts using CommonChunksPlugin
- for production, extract styles using ExtractTextPlugin
// EDIT
And this is all perfectly described in the documentation.

D
Dmitry Belyaev, 2016-05-12
@bingo347

1 style bundle, included in the head
1 js bundle, included at the very end, before the closing body

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question