Skip to content

Instantly share code, notes, and snippets.

@Pepeye
Created December 31, 2015 15:40
Show Gist options
  • Save Pepeye/ae90f48bffdbd2a091b0 to your computer and use it in GitHub Desktop.
Save Pepeye/ae90f48bffdbd2a091b0 to your computer and use it in GitHub Desktop.
Babel ES6/ES2015 + ES7/ES2016 settings
{
"presets": [
"es2015",
"react",
"stage-0"
],
"plugins": [
"transform-runtime",
"add-module-exports",
"transform-decorators"
]
}
@Pepeye
Copy link
Author

Pepeye commented Dec 31, 2015

Another option is to use babel-preset-node5 preset by @leebenson

{
  "presets": [
    "node5",
    "stage-0"
  ],
  "plugins": [
    ["transform-decorators"]
  ]
}

note, use of babel-plugin-transform-decorators to provide proposed ES7 style decorators - useful for both the Relay and Redux frameworks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment