drop-babel-typeof

v1.0.3
Remove the annoying _typeof(...) pollution when no symbol is used.
babel typeof symbol

drop-babel-typeof

If included as dev dependency, it can replace in place the annoying _typeof(...) indirection babel places to allow the usage of Symbol in the wild, even if symbols are not used.

drop-babel-typeof /some/file/path.js

Alternatively, if you are using @babel/preset-env, you can configure it like this so that it doesn't transform typeof:

["@babel/preset-env", {
  "exclude": "transform-typeof-symbol"
}]
npm i drop-babel-typeof

Metadata

  • ISC
  • Whatever
  • Andrea Giammarchi
  • released 1/10/2019

Downloads

Maintainers