
Product
Rust Support Now in Beta
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.
@gravityforms/dependency-extraction-webpack-plugin
Advanced tools
Dependency extraction webpack plugin for use in Gravity Forms development. Extends the WordPress plugin.
This plugin enhances the WordPress Dependency Extraction Webpack Plugin by adding automatic inclusion of Gravity Forms dependencies alongside WordPress dependencies. Use this if you are developing features or add-ons that extend Gravity Forms and want to use our externals instead of bundling our code yourselves. This is also used by the Gravity Forms plugin itself.
To install the module, use the following command:
npm install @gravityforms/dependency-extraction-webpack-plugin --save-dev
Integrate this plugin just like you would with the Dependency Extraction Webpack Plugin. The API remains identical, except for a few custom options we have added listed below, but it now also processes Gravity Forms packages automatically.
const GravityFormsDependencyExtractionWebpackPlugin = require('@gravityforms/dependency-extraction-webpack-plugin');
module.exports = {
// other webpack config
plugins: [new GravityFormsDependencyExtractionWebpackPlugin()],
};
You can pass an object to the constructor to modify the plugin's behavior, for instance:
module.exports = {
plugins: [
new GravityFormsDependencyExtractionWebpackPlugin({
bundledPackages: ['@gravityforms/libraries'],
}),
],
};
bundledPackages
This option specifies an array of packages to ignore during externals mapping. These packages will be included within your bundle and not mapped to the external.
An important note on our @gravityforms/components
package. If you pass @gravityforms/components
here, it will exclude all the components, but you can also pass @gravityforms/components/react/admin/modules/Dialog
to only exclude the Dialog component. This could be useful if you want to use a version of the package that has that component in a state that is ahead of what core has shipped with. All other components will map to our externals, but this one will be included in the bundle.
rootNamespace
If you are using our components by enqueuing the compiled files yourself instead of using the ones enqueued by Gravity Forms, you need to set this option to the same one you used in that package. Check the components readme for more details.
For more configuration options, refer to the original dependency extraction plugin.
FAQs
Dependency extraction webpack plugin for use in Gravity Forms development. Extends the WordPress plugin.
The npm package @gravityforms/dependency-extraction-webpack-plugin receives a total of 172 weekly downloads. As such, @gravityforms/dependency-extraction-webpack-plugin popularity was classified as not popular.
We found that @gravityforms/dependency-extraction-webpack-plugin demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 11 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.
Product
Socket Fix 2.0 brings targeted CVE remediation, smarter upgrade planning, and broader ecosystem support to help developers get to zero alerts.
Security News
Socket CEO Feross Aboukhadijeh joins Risky Business Weekly to unpack recent npm phishing attacks, their limited impact, and the risks if attackers get smarter.