# upload-vue-m

> 基于vue的图片上传插件

Latest version **1.1.5** (published 2019-05-30) · MIT license · 0 weekly downloads

## Install

```sh
npm install upload-vue-m
pnpm add upload-vue-m
yarn add upload-vue-m
bun add upload-vue-m
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.1.5 |
| Published | 2019-05-30 |
| First published | 2019-04-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 121.2 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Author | seikann |
| Maintainers | seikann |
| Keywords | vue, upload, 图片上传, 上传, 图片压缩, 多图上传, 图片旋转, ios rotate |

## Links

- npm: https://www.npmjs.com/package/upload-vue-m
- npm.io page: https://npm.io/package/upload-vue-m

## Dependencies (1)

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

## Recent versions

- 1.1.5 (latest) — 2019-05-30
- 1.1.4 — 2019-05-30
- 1.1.3 — 2019-05-30
- 1.1.2 — 2019-05-14
- 1.1.1 — 2019-05-14
- 1.1.0 — 2019-05-09
- 1.0.9 — 2019-05-09
- 1.0.8 — 2019-05-04
- 1.0.7 — 2019-05-04
- 1.0.6 — 2019-05-04
- 1.0.5 — 2019-04-30
- 1.0.4 — 2019-04-30
- 1.0.3 — 2019-04-30
- 1.0.2 — 2019-04-30
- 1.0.1 — 2019-04-30
- … 1 more at https://npm.io/package/upload-vue-m/versions

## README

# upload-vue-m
[![NPM version](https://img.shields.io/npm/v/upload-vue-m.svg)](https://www.npmjs.com/package/upload-vue-m)
> 基于vue的图片上传插件，移动PC皆可
## Build Setup

``` bash
# install dependencies
npm install

# serve with hot reload at localhost:8080
npm run dev

# build for production with minification
npm run build
```
## npm 安装
``` bash
npm install upload-vue-m --save
```
## 例
在main.js中引入
```js
import upload from 'upload-vue-m'
Vue.use(upload)
```
##在组件中使用
``` html
<seikann-upload
      @getWarning="getWarn" // 获取警告
      @getImages="getImages" // 获取需要上传的图文件流。fileList适用于formdata格式上传 和 showList图片展示
      uploadStyle="" // 设置上传dom样式 Object  例{width: '80px', height: '80px'}
      closeBtnStyle="" // 设置关闭按钮样式 Object
      accept="" // 设置上传文件格式 String
      maxSize="" // 设置最大文件限制 Number
      maxLength="" // 设置可上传的最大数量 Number
      isRepeat=""> // 设置是否允许上传重复图片 Boolean
    </seikann-upload>
```
## 版本
| 版本 | 备注 |
| ------ | ------ |
| 1.1.0 | 基于vue的上传图片基本功能，只是移动端、pc端 |
| 1.1.3 | 更新：修复手机端拍照上传 图片旋转bug |

## 参数

| 参数 | 类型 | 备注 | 必须 | 默认值 |
|  ------ | ------ | ------ | ------ | ------ |
| uploadStyle | Object | 设置上传dom样式 | 否 | {width: '80px',height: '80px','background-color': '#ccc'} |
| closeBtnStyle | Object | 设置关闭按钮样式 | 否 | {} |
| accept | String | 设置上传文件格式 | 否 | 'image/*' |
| maxSize | Number | 设置最大文件限制(M) | 否 | 10 |
| maxLength | Number | 设置可上传的最大数量 | 否 | 5 |
| isRepeat | Boolean | 设置是否允许上传重复图片 | 否 | false |


## 事件

| 事件 | 类型 | 备注 |
|  ------ | ------ | ------ |
| getWarning | event | 获取警告信息 |
| getImages | event | 获取需要上传的图文件流。fileList适用于formdata格式上传 和 showList图片展示 |

源码地址：[https://github.com/seikann/upload-vue-m](https://github.com/seikann/upload-vue-m)

For detailed explanation on how things work, consult the [docs for vue-loader](http://vuejs.github.io/vue-loader).

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