Skip to content

Commit 10046eb

Browse files
committed
doc: Update NProgress installtion
1 parent 16bf3d0 commit 10046eb

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

README.md

+11-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,17 @@ Then in your code:
1818
Vue.use(VueResourceNProgress);
1919

2020

21-
NOTE: You should have `NProgress` set globally (A example of this is adding `nprogress` plugin in `<script>` in `<head>`)
21+
NOTE: You should have `NProgress` installed globally.
22+
A example of this is adding `nprogress` plugin in `<script>` in `<head>`
23+
24+
### Using CommonJS
25+
26+
```
27+
npm i nprogress
28+
import NProgress from 'nprogress'
29+
window.NProgress = NProgress
30+
require('nprogress/nprogress.css')
31+
```
2232

2333
## Configuration
2434

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-resource-nprogress",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"description": "Interceptor that ties a progressbar to all requests, that it is clear that something is loading",
55
"main": "dist/vue-resource-nprogress.es5.js",
66
"repository": {

0 commit comments

Comments
 (0)