Entry Generator Webpack Plugin
A Webpack plugin to dynamically generate an entry file on compiler initialisation
Sometimes you will want to generate an entry file dynamically. This file may consist of your bower dependencies or it may be a test suite that consists of all your unit test specification files.
This plugin will generate such a file if it is not already present. You may depende your compiler upon the output of this plugin.
The plugin is of the following form.
function|Array.<function>of methods that return a list of files or promise to such
The following configuration generates a
vendor.js files that consists of your bower
var EntryGeneratorWebpackPlugin =moduleexports =entry;vendor: 'vendor.js'......plugins:'vendor.js'EntryGeneratorWebpackPlugin......
The sources are one or more
function([outputPath:string]):Array.<string>|Promise. It returns a list of files relative to the given output path or a list of module names or a promise that resolves to such.
There are a number of source factories exported on
EntryGeneratorWebpackPlugin, these include:
A source factory that will list bower modules from the
dependenciesfield of the
bower.jsonfile in the Webpack
optionsmay include any of the standard Webpack file filters (although applied to the module names), meaning
As above, for the
A source factory that can glob files rooted in the Webpack
contextdirectory. It supports
optionsper glob properties. The
optionsmay also include any of the standard Webpack file filters (although applied to the module names), meaning
exclude. Note however that it is more efficient to use the glob
ignoreproperty than the Webpack