1.1.0 • Published 6 years ago

webpack-optional-plugin v1.1.0

Weekly downloads
2
License
MIT
Repository
github
Last release
6 years ago

webpack-optional-plugin

Load a file from disk if it exists, otherwise yield a pre-defined null value.

Usage

See the provided example.

Options

include

Type: String|RegExp|Array.<String>|Array.<RegExp>

nullModulePath

Type: String

Defaults to webpack-optional-plugin/null.js.

enabled

Type: Boolean

Set to false to yield the null module for matching files even regardless of whether the source file exists or not.

This option is intended for use when building for production so that the optional files aren't included in the bundle.

Changelog

1.1.0

  • Added the enabled flag
1.1.0

6 years ago

1.0.0

6 years ago