Skip to content

Instantly share code, notes, and snippets.

@codeck
Created August 25, 2015 03:35
Show Gist options
  • Save codeck/f31c7fb162a62113c920 to your computer and use it in GitHub Desktop.
Save codeck/f31c7fb162a62113c920 to your computer and use it in GitHub Desktop.
how to run es6 javascript
#apt-get install npm
#ln -s /usr/bin/nodejs /usr/bin/node
echo 'prefix = ${HOME}/.npm-packages' >> ~/.npmrc
git clone https://github.com/stellar/js-stellar-base.git && cd js-stellar-base
npm install -g babel
npm install
babel-node examples/test.js
@codeck
Copy link
Author

codeck commented Dec 3, 2015

in babel 6, additional steps required:
$npm install --save-dev babel-preset-s2015
and save

{
  "presets": ["es2015"]
}

in project_root/.babelrc

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