1.0.5 • Published 2 years ago

video-upload v1.0.5

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

video-upload

  • 🔥 Written in Javascript

Getting Started

Allright, if you want to implement a quick search, maybe you could use this. It mainly for video upload by fragment. Hope it can help complete your work smoothly

Install

npm

npm install video-upload

cnpm

cnpm install video-upload

yarn

yarn add video-upload

Use

This is a js for use you can import it and use as follows

import VfUpload from 'video-upload'

const upload = new UploadVideo()

  upload.init({
    file: file, // 要上传的视频文件
    size: 1, // 单词要上传的视频大小 (M)
    url: 'https://run.mocky.io/v3/9d059bf9-4660-45f2-925d-ce80ad6c4d15', // 上传路径
    method: 'post', // 上传方法
    progressCallback: (pro) => { // 每一片段上传成功后的回调函数
      progress.value = pro
    },
    compelteCallback: () => { // 全部上传完成的回调函数
      console.log('complte')
    },
  })

It would expose an constructor for you to init some params where you could complete video upload work

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago