babel/packages/babel-plugin-transform-es2015-classes
Amjad Masad 95c93dd22b Method names should not be bound to body
As an artificat of compiling methods to named function expressions the
function name is being considered a "local" binding in the function
body. This means that we will throw errors anytime someone would want to
create a new local binding with the same name.

This is solved by assigning a symbol to function Identifiers that
indicates that they should not be considered local bindings.
2016-01-17 13:19:37 -08:00
..
2016-01-06 15:34:12 -05:00
2015-09-15 06:12:46 +01:00

babel-plugin-transform-es2015-classes

Compile ES2015 classes to ES5

Installation

$ npm install babel-plugin-transform-es2015-classes

Usage

.babelrc

{
  "plugins": ["transform-es2015-classes"]
}

Via CLI

$ babel --plugins transform-es2015-classes script.js

Via Node API

require("babel-core").transform("code", {
  plugins: ["transform-es2015-classes"]
});