Webpack 2 is super cool, I wrote a sample boiler code that you can reuse to spin a Express application and setup to deploy to Heroku instantly.
Few things to remember that :
-
No Fancy framework or platform are used here, this is clear naked/raw boilerplate, and I'll let you decide to pick your faviorte framework on top of this.
-
This boilerplate use HMR and it is cool.
Clone this code and follow these instructions
npm i
npm start
- Visit http://localhost:3000/
First, you'll need a heroku account.
- In Heroku, create a new app
- Add a new buildpack, select
heroku/nodejs
. This should set you up to automatically runnpm install
which is what you'll need to get up and running.
- Follow the instructions to link your repository
git push heroku master
- Assuming you've set everything up correctly, this will deploy your app, and run the postinstall script inpackage.json
.