diff --git a/README.md b/README.md index fb382e4f..d3ef2273 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ $ npm run build Build the extension into `dist` folder for **production**. -### `npm run build:env` +### `npm run build:dev` Build the extension into `dist` folder for **development**. @@ -38,6 +38,10 @@ Build the extension into `dist` folder for **development**. Watch for modifications then run `npm run build`. +### `npm run watch:dev` + +Watch for modifications then run `npm run build:web`. + ### `npm run build-zip` Build a zip file following this format `-v.zip`, by reading `name` and `version` from `manifest.json` file. diff --git a/template/package.json b/template/package.json index 259e714b..7ee3b0e8 100644 --- a/template/package.json +++ b/template/package.json @@ -5,9 +5,10 @@ "author": "{{ author }}", "scripts": { "build": "cross-env NODE_ENV=production webpack --config webpack.config.js --progress --hide-modules", - "build:env": "cross-env NODE_ENV=development webpack --config webpack.config.js --progress --hide-modules", + "build:dev": "cross-env NODE_ENV=development webpack --config webpack.config.js --progress --hide-modules", "build-zip": "node scripts/build-zip.js", - "watch": "npm run build -- --watch" + "watch": "npm run build -- --watch", + "watch:dev": "npm run build:dev -- --watch" }, "dependencies": { {{#axios}}"axios": "^0.16.2",{{/axios}} diff --git a/template/src/popup/popup.html b/template/src/popup/popup.html index 5f0d5a88..70974f0f 100644 --- a/template/src/popup/popup.html +++ b/template/src/popup/popup.html @@ -3,6 +3,7 @@ Title +
diff --git a/template/src/popup/router/routes.js b/template/src/popup/router/routes.js index 0e28735e..1a913a42 100644 --- a/template/src/popup/router/routes.js +++ b/template/src/popup/router/routes.js @@ -1,6 +1,8 @@ +import PageIndex from './pages/Index.vue'; + export default [ { path: '/', - component: require('./pages/Index.vue') + component: PageIndex }, ];