Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

babel-plugin-class-display-name

ftdebugger9.6kMIT2.1.0

Add displayName propery to classes to prevent lost information during name mangling

readme

babel-plugin-class-display-name Build Status

Add displayName property to class constructors to prevent it lost during minification

Installation

$ npm install babel-plugin-class-display-name

Usage

.babelrc

{
  "plugins": ["class-display-name"]
}

Via CLI

$ babel --plugins class-display-name script.js

Via Node API

require("babel-core").transform("code", {
  plugins: ["class-display-name"]
});