You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
thescientist13 opened this issue
Aug 26, 2019
· 0 comments
Assignees
Labels
PluginsGreenwood PluginsRFCProposal and changes to workflows, architecture, APIs, etcv0.4.0Plugins and PackageswebsiteTasks related to the projects website / documentation
Taken from a comment in #17 (comment) in regards to a general discussion around the API and capturing the specific action item re: build plugin type here.
Details
Build
Basically you can pass a webpack plugin! Mileage may vary, but we could provide a list of known plugins that work in this way. (like ones that we use in our own plugins)
Usage
For a consumer, usage would look something like this in greenwood.config.js where the provider function in this case returns an instance of a webpack plugin.
example:
const{ version }=require('package.json');constwebpack=require('webpack');module.exports={title: 'My App'...plugins: [{type: 'build'provider: (compilation)=>{const{ config }=compilation;returnnewwebpack.BannerPlugin({banner: `${config.title} v${version}: built on ${newDate().getTime()}`});}]}
The text was updated successfully, but these errors were encountered:
PluginsGreenwood PluginsRFCProposal and changes to workflows, architecture, APIs, etcv0.4.0Plugins and PackageswebsiteTasks related to the projects website / documentation
Type of Change
Summary
Taken from a comment in #17 (comment) in regards to a general discussion around the API and capturing the specific action item re:
build
plugin type here.Details
Build
Basically you can pass a webpack plugin! Mileage may vary, but we could provide a list of known plugins that work in this way. (like ones that we use in our own plugins)
Usage
For a consumer, usage would look something like this in greenwood.config.js where the
provider
function in this case returns an instance of a webpack plugin.example:
The text was updated successfully, but these errors were encountered: