Skip to content

Latest commit

 

History

History
42 lines (35 loc) · 1.04 KB

README.md

File metadata and controls

42 lines (35 loc) · 1.04 KB

babel-me

Are you planning to use babel in your next project ? Build a Babel environment in one single line

#Install

npm install -g babel-me

#Usage

babel-me

Create a simple environment for start coding in es6 with babel.

.
|___ lib/index.js     <-- base es6 file
|___ dist/            <-- distribution folder
|___ tests/test.js    <-- base es6 test based on mocha
|___ .babelrc         <-- babel configuration file

Aumatically add scripts to use and build your babel lib

...
"scripts":{
  "build" : "./node_modules/babel-cli/bin/babel.js lib -d dist",
  "test" : "./node_modules/mocha/bin/mocha tests/* --compilers js:babel-core/register -t 15s",
  "prepublish" : "npm run build"
},

Install the minimumm required dependencies

  • babel-cli
  • babel-core
  • babel-preset-es2015
  • mocha

Thats all! Simple and with minimum dependencies.

Related

A babel boilerplate for Yeoman https://github.com/babel/generator-babel-boilerplate