Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 

readme.md

The default riot babel preset

Build Status

This preset includes all the default babel es2015 plugins Allowing the use of the es2015 modules also in any riot tag

Installation

$ npm install babel-preset-es2015-riot --save-dev

Usage

Add a .babelrc file in the root of your project

{
  "presets": [ "es2015-riot" ]
}

If you want to use the babel helpers you must change the .babelrc file in this way:

{
  "presets": [ "es2015-riot" ],
  "plugins": [ "external-helpers-2" ]
}

Babel 7

If you are using babel 7 you don't need to use this preset at all. You can simply configure your .babelrc in this way:

{
  "presets": [
    [
      "@babel/preset-env",
      {
        "modules": false,
        "targets": [
          // wathever you need to support
          "last 2 versions"
        ]
      }
    ]
  ]
}

Remeber to install via npm the @babel/core@7 and @babel/preset-env@7 dependencies

About

The default riot babel preset

Resources

License

Releases

No releases published

Packages

No packages published
You can’t perform that action at this time.