babel-plugin-filter-imports weekly downloads statistics
By ember-cli (3 listings) · npm · Babel plugins
A babel transform for filtering out imports
babel-plugin-filter-imports has 129,488 recorded weekly downloads on npm, a decrease of 2.0% over the past 30 days, ranking #602 of 3,247 tracked listings.
About babel-plugin-filter-imports
babel-plugin-filter-imports
This babel plugin is used to removed references to imports within a module. This can be useful for removing debugging statements when doing a production build of your code. It is often used in conjunction with other tools like Uglify that perform dead code elimination.
Installation
$ yarn add --dev babel-plugin-filter-imports
This plugin is for Babel 7. If you need to support:
Example
Given the .babelrc
{
"plugins": [["filter-imports", {
"imports": {
"debugging-tools": [ "warn" ]
}
}]]
}
the module
import { warn } from 'debugging-tools';
function join(args, sep) {
if (arguments.length > 2) {
warn("join expects at most 2 arguments");
}
return args.join(sep);
}
will be transformed to
function join(args, sep) {
if (arguments.length > 2) {
}
return args.join(sep);
}
Configuration
options[keepImports][Boolean]: An flag that indicates imports removal from header.options[imports][Object]: An object whose keys are names of modules.options[imports][moduleName][String]: An array of names of imports frommoduleNameto be removed. You can include'default'for default export and'*'for a namespace export.
Upgrade to 1.x/2.x
There were breaking changes in the plugin configuration, you must update it to work correctly.
Before 1.x
{
"plugins": [["filter-imports", {
"debugging-tools": [ "warn" ]
}]]
}
After
{
"plugins": [["filter-imports", {
"imports": {
"debugging-tools": [ "warn" ]
}
}]]
}
Description from the npm listing.
- babel
- babel-plugin
README badge
Show your rank in a README or on your website. The badge updates automatically.
Charts
Images: 30d · 1y · all time · 1600×900 dark
Adoption over time
7/30/90-day growth
Ranking history
Listing placement
Listing placement
Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.
Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.
Recent observations
Full history (592)Similar npm Babel plugins plugins
All 20 babel-plugin-filter-imports alternativesData source
Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.
Listing: https://www.npmjs.com/package/babel-plugin-filter-imports. First seen Oct 16, 2026; last successful collection Dec 6, 2026. See the methodology.