Pass config.open to browsersync-webpack-plugin

This commit is contained in:
Jan Grzegorowski
2017-07-01 19:39:12 -07:00
committed by
parent a67d5001f3
commit a429115fb2
5 changed files with 29 additions and 17 deletions

36
package-lock.json generated
View File

@@ -154,7 +154,8 @@
"ansi-styles": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.1.0.tgz",
"integrity": "sha1-CcIC1ckX7CMYjKpcnLkXnNlUd1A="
"integrity": "sha1-CcIC1ckX7CMYjKpcnLkXnNlUd1A=",
"dev": true
},
"anymatch": {
"version": "1.3.0",
@@ -601,9 +602,9 @@
"dev": true
},
"browsersync-webpack-plugin": {
"version": "0.5.3",
"resolved": "https://registry.npmjs.org/browsersync-webpack-plugin/-/browsersync-webpack-plugin-0.5.3.tgz",
"integrity": "sha1-Nbw7HFq6jH0te3AOI9URRUuNUW4=",
"version": "0.6.0",
"resolved": "https://registry.npmjs.org/browsersync-webpack-plugin/-/browsersync-webpack-plugin-0.6.0.tgz",
"integrity": "sha1-eAGEX+n3cahpVPh3bCzdiqggzBQ=",
"dev": true
},
"bs-html-injector": {
@@ -791,7 +792,8 @@
"chalk": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-2.0.1.tgz",
"integrity": "sha512-Mp+FXEI+FrwY/XYV45b2YD3E8i3HwnEAoFcM0qlZzq/RZ9RwWitt2Y/c7cqRAz70U7hfekqx6qNYthuKFO6K0g=="
"integrity": "sha512-Mp+FXEI+FrwY/XYV45b2YD3E8i3HwnEAoFcM0qlZzq/RZ9RwWitt2Y/c7cqRAz70U7hfekqx6qNYthuKFO6K0g==",
"dev": true
},
"chokidar": {
"version": "1.7.0",
@@ -928,7 +930,8 @@
"color-convert": {
"version": "1.9.0",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.0.tgz",
"integrity": "sha1-Gsz5fdc5uYO/mU1W/sj5WFNkG3o="
"integrity": "sha1-Gsz5fdc5uYO/mU1W/sj5WFNkG3o=",
"dev": true
},
"color-diff": {
"version": "0.1.7",
@@ -939,7 +942,8 @@
"color-name": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.2.tgz",
"integrity": "sha1-XIq3K2S9IhXWF66VWeuxSEdc+Y0="
"integrity": "sha1-XIq3K2S9IhXWF66VWeuxSEdc+Y0=",
"dev": true
},
"color-string": {
"version": "0.3.0",
@@ -2191,7 +2195,8 @@
"escape-string-regexp": {
"version": "1.0.5",
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=",
"dev": true
},
"escodegen": {
"version": "1.8.1",
@@ -3858,7 +3863,8 @@
"has-flag": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/has-flag/-/has-flag-2.0.0.tgz",
"integrity": "sha1-6CB68cx7MNRGzHC3NLXovhj4jVE="
"integrity": "sha1-6CB68cx7MNRGzHC3NLXovhj4jVE=",
"dev": true
},
"has-gulplog": {
"version": "0.1.0",
@@ -5821,7 +5827,8 @@
"postcss": {
"version": "6.0.4",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-6.0.4.tgz",
"integrity": "sha1-VzrN33P0LsskqmGNQO49WnwEplQ="
"integrity": "sha1-VzrN33P0LsskqmGNQO49WnwEplQ=",
"dev": true
},
"postcss-calc": {
"version": "5.3.1",
@@ -7058,7 +7065,8 @@
"postcss-safe-parser": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/postcss-safe-parser/-/postcss-safe-parser-3.0.0.tgz",
"integrity": "sha1-AhTXOut22okyMH2To3oZMuhBJNM="
"integrity": "sha1-AhTXOut22okyMH2To3oZMuhBJNM=",
"dev": true
},
"postcss-scss": {
"version": "0.4.1",
@@ -8077,7 +8085,8 @@
"source-map": {
"version": "0.5.6",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.5.6.tgz",
"integrity": "sha1-dc449SvwczxafwwRjYEzSiu19BI="
"integrity": "sha1-dc449SvwczxafwwRjYEzSiu19BI=",
"dev": true
},
"source-map-resolve": {
"version": "0.3.1",
@@ -8572,7 +8581,8 @@
"supports-color": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-4.1.0.tgz",
"integrity": "sha1-kswUuz2tiSjKVlbDPhmhnyCvXHo="
"integrity": "sha1-kswUuz2tiSjKVlbDPhmhnyCvXHo=",
"dev": true
},
"svg-tags": {
"version": "1.0.0",

View File

@@ -91,7 +91,7 @@
"devDependencies": {
"autoprefixer": "~7.1",
"browser-sync": "~2.18",
"browsersync-webpack-plugin": "^0.5.3",
"browsersync-webpack-plugin": "^0.6.0",
"bs-html-injector": "~3.0",
"buble-loader": "^0.4.1",
"clean-webpack-plugin": "^0.1.16",

View File

@@ -12,6 +12,7 @@ const rootPath = (userConfig.paths && userConfig.paths.root)
: process.cwd();
const config = merge({
open: true,
copy: 'images/**/*',
proxyUrl: 'http://localhost:3000',
cacheBusting: '[name]_[hash]',

View File

@@ -26,6 +26,7 @@ module.exports = {
new webpack.NoEmitOnErrorsPlugin(),
new BrowserSyncPlugin({
target,
open: config.open,
proxyUrl: config.proxyUrl,
watch: config.watch,
delay: 500,

View File

@@ -587,9 +587,9 @@ browserslist@^2.0.0, browserslist@^2.1.3:
caniuse-lite "^1.0.30000684"
electron-to-chromium "^1.3.14"
browsersync-webpack-plugin@^0.5.3:
version "0.5.3"
resolved "https://registry.yarnpkg.com/browsersync-webpack-plugin/-/browsersync-webpack-plugin-0.5.3.tgz#35bc3b1c5aba8c7d2d7b700e23d511454b8d516e"
browsersync-webpack-plugin@^0.6.0:
version "0.6.0"
resolved "https://registry.yarnpkg.com/browsersync-webpack-plugin/-/browsersync-webpack-plugin-0.6.0.tgz#7801845fe9f771a86954f8776c2cdd8aa820cc14"
dependencies:
webpack-merge "^4.1.0"
optionalDependencies: