## Setting up Babel and nodemon ### Inital set-up Set up project: ```bash mkdir project cd project npm init -y ``` Install dev dependencies: npm i --save-dev babel-cli babel-preset-latest nodemon Configure Babel by adding the lines below to `package.json`: ```json "babel": { "presets": [ "latest" ] }, ``` ### Scripts Add some convenience scripts to `package.json`: ```json "scripts": { "babel-node": "babel-node --presets=latest", "start": "nodemon --exec npm run babel-node -- ./index.js", "build": "babel src -d dist" }, ``` To start the Node.js REPL: npm run babel-node To start the app in development mode (letting Babel interpret ES6 code): npm start To build the ES5 code in the `build` directory from the ES6 code in the `src` directory: npm build