# vue-filereader

> FileReader component for Vue.js

Latest version **0.1.1** (published 2019-04-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install vue-filereader
pnpm add vue-filereader
yarn add vue-filereader
bun add vue-filereader
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2019-04-04 |
| First published | 2019-03-23 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 102.3 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| GitHub stars | 1 |
| Author | magr0s |
| Maintainers | magr0s |
| Keywords | filereader, vue |

## Links

- npm: https://www.npmjs.com/package/vue-filereader
- Repository: https://github.com/magr0s/vue-filereader
- Homepage: https://github.com/magr0s/vue-filereader#readme
- Issues: https://github.com/magr0s/vue-filereader/issues
- npm.io page: https://npm.io/package/vue-filereader

## Dependencies (1)

- [vue](https://npm.io/package/vue.md) ^2.6.6

## Recent versions

- 0.1.1 (latest) — 2019-04-04
- 0.1.0 — 2019-03-23

## README

# Vue FileReader ![Current version](https://img.shields.io/badge/dynamic/json.svg?label=version&url=https%3A%2F%2Fraw.githubusercontent.com%2Fmagr0s%2Fvue-filereader%2Fmaster%2Fpackage.json&query=version&colorB=orange&style=flat-square) 

![Vue.js version](https://img.shields.io/badge/dynamic/json.svg?label=vue.js&url=https%3A%2F%2Fraw.githubusercontent.com%2Fmagr0s%2Fvue-filereader%2Fmaster%2Fpackage.json&query=dependencies.vue&colorB=blue&style=flat-square)
![License](https://img.shields.io/badge/license-MIT-lightgrey.svg?&style=flat-square)

Vue.js component

## Install

#### NPM
```
npm i vue-filereader --save
```

## Usage
```js
import FileReader from 'vue-filereader'

// mount
...
components: {
  FileReader
}
...

// mount with global
Vue.component(FileReader.name, FileReader)
```

**Default tag**
```html
<!-- 
  Output data:
  array - ArrayBuffer
  binary - BinaryString
  data - DataUrl
  text - TextString (default)
-->
<file-reader
  accept=".txt"
  output="binary"
  @reader-load="myMethod"
/>
```
**Customization**
```html
<file-reader
  accept=".txt"
  output="binary"
  @reader-load="myMethod"
>
  <template
    #reader="props"
  >
    <input
      type="file"
      :accept="props.accept"
      @change="props.onchange"
    />
  </template>
</file-reader>
```

## Development

#### Compiles and hot-reloads for development
```
npm run serve
```

#### Compiles and minifies for production
```
npm run build:lib
```

#### Lints and fixes files
```
npm run lint
```
### Author

[magr0s](https://github.com/magr0s)

### License

[MIT](https://github.com/magr0s/vue-filereader/blob/master/LICENSE)

---
_Source: https://npm.io/package/vue-filereader · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
