webpack-load-plugins icon indicating copy to clipboard operation
webpack-load-plugins copied to clipboard

webpack plugins included

Open PatrickJS opened this issue 9 years ago • 7 comments

are the webpack plugins also included? for example webpack.optimize. UglifyJsPlugin

PatrickJS avatar Feb 11 '16 01:02 PatrickJS

sorry for the late answer, did not see the notice..

only the webpack plugins defined in the packages.json are included: https://github.com/samvloeberghs/webpack-load-plugins/blob/master/index.js#L25 & https://github.com/samvloeberghs/webpack-load-plugins/blob/master/index.js#L55

samvloeberghs avatar Feb 23 '16 15:02 samvloeberghs

can we also include the default plugins so the user doesn't need to require "webpack"

PatrickJS avatar Feb 23 '16 15:02 PatrickJS

I could take a look into that, will see what I can do in what timespan :)

samvloeberghs avatar Feb 23 '16 15:02 samvloeberghs

ping

PatrickJS avatar Jun 20 '16 00:06 PatrickJS

How do you see this @gdi2290? I'm struggling with what would be a good approach on this?

Right now you should include webpack using require('webpack') and then use something like: new webpack.optimize.OccurenceOrderPlugin(true). How would this help to put these into the "webpack-load-plugins" plugin? It would mean I just need to require webpack as a whole, at first sight.

samvloeberghs avatar Jun 20 '16 06:06 samvloeberghs

@gdi2290 bump!

samvloeberghs avatar Sep 02 '16 06:09 samvloeberghs

ya just auto add the webpack plugins plugins.namedModules -> NamedModulesPlugin plugins.define -> DefinePlugin plugins.dedupe -> DedupePlugin plugins.uglifyJs -> UglifyJsPlugin

PatrickJS avatar Sep 02 '16 21:09 PatrickJS