The plugins
option is used to customize the Rspack build process in a variety of ways. Rspack comes with a variety built-in plugins available under rspack.[plugin-name]
. See Plugins page for a list of plugins and documentation but note that there are a lot more out in the community.
Array<RspackPluginInstance | RspackPluginFunction | RspackBuiltinPlugin>
[]
An array of webpack plugins. For example, DefinePlugin
allows you to create global constants which can be configured at compile time. This can be useful for allowing different behavior between development builds and release builds.
Rspack strives to maintain compatibility with the webpack plugin ecosystem to leverage the excellent features that have been accumulated and validated by the community. Please refer to the Plugin Compatibility List to access a list of webpack plugins that have passed our compatibility tests: