Gulp + live reload serves up my content on localhost and (here\'s what I\'m after) launches the browser automatically at the server url whenever i run the gulp
directory/folder: package.json
{
"devDependencies": {
"babel-core": "^6.26.3",
"babel-loader": "^7.1.5",
"babel-preset-es2015": "^6.24.1",
"babel-preset-react": "^6.24.1",
"webpack": "^4.16.0",
"webpack-dev-server": "^3.1.4"
},
"name": "",
"version": "1.0.0",
"main": "index.js",
"license": "MIT",
"description": "",
"author": "",
"private": false,
"scripts": {
"start": "webpack-dev-server --open --watch"
},
"dependencies": {
"webpack-cli": "^3.0.8"
}
}
This start script will run the dev server, and both automatically open and update (on-save) the web page. This is for WebPack 4.