Skip to content

Commit 2aea155

Browse files
committed
Add npm hot reload
1 parent ddd623c commit 2aea155

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

package.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"description": "Simple clock using vue.js",
55
"main": "index.js",
66
"scripts": {
7-
"test": "echo \"Error: no test specified\" && exit 1"
7+
"server": "http-server",
8+
"watch": "rollup -c -w",
9+
"dev": "npm-run-all --parallel watch server"
810
},
911
"repository": {
1012
"type": "git",
@@ -18,8 +20,13 @@
1820
"homepage": "https://github.com/dangvanthanh/vue-clock#readme",
1921
"devDependencies": {
2022
"babel-preset-es2015-rollup": "^1.1.1",
23+
"http-server": "^0.9.0",
24+
"npm-run-all": "^2.2.0",
2125
"rollup": "^0.32.0",
2226
"rollup-plugin-babel": "^2.5.1",
2327
"rollup-plugin-vue": "^2.0.1"
28+
},
29+
"dependencies": {
30+
"rollup-watch": "^2.4.0"
2431
}
2532
}

readme.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,13 @@
33
> Simple clock component using vue.js
44
55
![Simple clock component using vue.js](https://raw.githubusercontent.com/dangvanthanh/vue-clock/master/media/clock-using-vue.png)
6+
7+
## Build
8+
9+
```
10+
# Install dependencies
11+
npm install
12+
13+
# Serve with hot reload at localhost:8080
14+
npm run dev
15+
```

0 commit comments

Comments
 (0)