React + webpack protip #4827
Arnaud Rinquin

If you do that, you trade the nuisance of having to import react in all components, for locking yourself in to webpack + define plug-in while breaking the static analysis ES2015 modules provide (which in turn limits you even more, like not being able to use tree shaking - a feature of webpack 2 and rollup).

Which may be a reasonable tradeoff to make, as long as you’re aware of the cost. :)

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.