Skip to content

Commit 171e65b

Browse files
author
Guillaume Chau
authored
Add a note about using npm packages
1 parent 66ca211 commit 171e65b

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

packages/vue-component/README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,26 @@ For example, you can add the following `.vueignore` file to your app inorder to
144144
node_modules/
145145
```
146146

147+
### Using Vue npm packages
148+
149+
Most of the time, you need to ignore the compilation of Vue files inside the `node_modules` directory.
150+
151+
Add a .vueignore in the project root with the following content:
152+
153+
```
154+
node_modules/
155+
```
156+
157+
The npm packages should have distribution/compiled files (or try to tell their authors if they are missing). You should directly import these if you have any issue.
158+
159+
For example, to use the [keen-ui](https://github.com/JosephusPaye/keen-ui) package, install the plugin in your app using the dist files:
160+
161+
```javascript
162+
import 'keen-ui/dist/keen-ui.min.css'
163+
import KeenUI from 'keen-ui/dist/keen-ui.min.js'
164+
Vue.use(KeenUI)
165+
```
166+
147167
---
148168

149169
## Next steps

0 commit comments

Comments
 (0)