🚀 DAY 5 OF LAUNCH WEEK: Introducing Socket Firewall Enterprise.Learn more →
Socket
Book a DemoInstallSign in
Socket

babel-plugin-danger-remove-unused-import-taro

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-danger-remove-unused-import-taro

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

babel-plugin-danger-remove-unused-import

To shrink the bundle javascript size :smile:

Note: remove unused import is dangerous
because the imported package may have some side effects!

Option

{
  ignore: ['react']
}

Input

import React from 'react'
import Button from 'button'
import _ from 'lodash'
import moment from 'moment'
import {data} from '../some-where'

// ...

const a = {}
a.moment = <Button x={data} />

Output

import React from 'react'
import Button from 'button'
- import _ from 'lodash'
- import moment from 'moment'
import {data} from '../some-where'

// ...

const a = {}
a.moment = <Button x={data} />

ChangeLog

  • 1.0.9
    Fix <Comp.A/> Bug

Todo

  • Supporting Scope

Keywords

remove-unused

FAQs

Package last updated on 05 Nov 2018

Did you know?

Socket

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.

Install

Related posts