package
Webpack plugin for legacy browser transcompilation (including dependencies)
npm install targets-webpack-pluginGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Latest published Nov 17, 2021
latest
A babel plugin for transcompiling final bundles so they support legacy browsers.
This plugin runs babel and rollup only once per asset, at the end of the compilation process.
npm install --save-dev targets-webpack-pluginor
yarn add --dev targets-webpack-pluginAdd TargetsPlugin to the list of plugins.
// next.config.js
const TargetsPlugin = require("targets-webpack-plugin");
module.exports = {
webpack: function (config, { dev }) {
if (!dev) {
config.plugins.push(new TargetsPlugin({
browsers: ["last 2 versions", "chrome >= 41"]
}))
}
return config
}
}MIT
Estimated unpacked size across 64 packages.
25.8 MB+
Includes dependencies.
9 direct · 5 outdated
^2.60.0
4.68.3
^3.19.1
3.51.0
^5.64.1
5.112.2
^7.16.0
8.1.2
^3.2.2
3.7.0
^7.16.4
8.0.7
^21.0.1
29.0.3
2.1.1
^13.0.6
16.0.3