vue-doc-reader
v0.1.4
Published
file input reader for docs
Downloads
22
Maintainers
Readme
file input reader for docs
Supported Formats
.xlsx .xlsb .xlsm .xls .xml .csv
Prerequisites
- node >=10
Install
npm i vue-doc-reader
Usage
In main.ts
import VueDocReader from 'vue-doc-reader'
Vue.component('vue-doc-reader',VueDocReader)
In parent component template
<vue-doc-reader @onLoad="onLoad" />
Props
- (optional) label:string - input label.
- (optional) includeRows:boolean - if
true
the table data will return withrowIndex
property for each row.
Callback
onLoad event callback return {data:Array<any>,headers:Array<string>}
data
represents array of row objects[columnName:string]:value
headers
represents array of columns name
onLoad(results:any){
this.data = results.data;
this.headers = results.headers
}
Author
👤 daniel212
Show your support
Give a ⭐️ if this project helped you!
This README was generated with ❤️ by readme-md-generator