makestatic-core-standard
v2.0.2
Published
Standard lifecycle configuration
Downloads
6
Readme
Core Standard
Standard lifecycle configuration
Install
yarn add makestatic-core-standard
API
StandardLifeCycle : LifeCycle
Standard lifecycle configuration for the core library.
This standard configuration is used by the command line interface.
Configures the lifecycle with standard plugins for these phases:
clean
: Adds theclean-output
plugin.build
: Adds thehttp-cache
plugin.load
: Adds thesources-loader
plugin.pack
: Adds thepack-webpack
plugin unlesspack
isfalse
.resolve
: Adds theresolve-file
plugin.emit
: Adds theemit-gzip
plugin ifgzip
istrue
.manifest
: Adds themanifest
plugin ifmanifest
istrue
.write
: Adds thewrite-file
plugin.deploy
: Adds thedeploy-site
plugin if a provider is given.
Plugins are merged with any existing definitions in the lifecycle so as not to conflict with user-defined lifecycle configurations for the phases that are modified however the plugins configured here take precedence in terms of execution order. In practice, due to the nature of the lifecycle execution the plugin order should not make any difference to the result as a plugin can only be guaranteed a previous plugin has completed execution if it exists in a preceeding phase.
See Also
- Command Line Interface
- Core Library
- Clean Output
- HTTP Agent
- Sources Loader
- Pack Webpack
- Resolve File
- Emit Gzip
- Write File
- Deploy Site
StandardLifeCycle : LifeCycle
new StandardLifeCycle(options)
Create a StandardLifeCycle.
options
Object configuration options.
.getLifeCycleConfig
StandardLifeCycle.prototype.getLifeCycleConfig(opts, argv)
Configures various plugins for the lifecycle phases.
Returns lifecycle configuration map.
opts
Object map of computed options.argv
Object configuration overrides.
License
MIT
Created by mkdoc on March 12, 2017