The name is totally random. This boilerplate has:
- Hapi.js
- Postgres (pg-postgres, migrations)
- HAL
- A somewhat oppinnionated structure
- ES6 (requires Node 5)
- Install postgres
- Install Node.js
npm installcat db/init.sql | psqlnpm run db:migrate:up
- create migration: (assuming you have
npm install db-migrate -g)db-migrate --env test --migrations-dir=./db/.migrations --config db/database.json create <name>
npm run dev to start Hapi application server
npm run webpack in another terminal session to start webpack dev server with hot module reloading
npm run build to generate config files and webpack assets. This means we don't need to run webpack dev server in production.
npm start to start up node
Visit http://localhost:2000 (note the port is different from dev)