Skip to content

Commit bee86c2

Browse files
committed
exclude demo in package, updated readme
1 parent f873474 commit bee86c2

File tree

3 files changed

+59
-2
lines changed

3 files changed

+59
-2
lines changed

.npmignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Exclude files/folders for publishing package
2+
3+
demo/
4+

README.md

Lines changed: 54 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,55 @@
1-
# vue-file-selector
1+
# Vue File selector
22
File selector component that supports drag-n-drop for @vuejs
3+
4+
## Install
5+
Run the command
6+
```
7+
npm i fluent-reveal-effect@latest
8+
```
9+
10+
NPM package: https://www.npmjs.com/package/vue-file-selector
11+
12+
## Usage
13+
14+
#### Declare the plugin
15+
```js
16+
// import the library
17+
import FileSelector from 'vue-file-selector';
18+
19+
// then use it!
20+
Vue.use(FileSelector);
21+
```
22+
23+
### Use in Vue file
24+
```html
25+
<template>
26+
<div>
27+
My App.vue comp
28+
29+
<file-selector
30+
accept-extensions=".zip"
31+
:height="300"
32+
@validate="validate"
33+
@change="change"
34+
>
35+
hahahah
36+
</file-selector>
37+
</div>
38+
</template>
39+
40+
<script>
41+
export default {
42+
name: 'App',
43+
methods: {
44+
validate(result, files) {
45+
console.log('Validation result: ' + result);
46+
},
47+
48+
change(files) {
49+
console.log('Selected files: ', files);
50+
},
51+
},
52+
};
53+
</script>
54+
```
55+

dist/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)