1.1.2 • Published 3 days ago

vue-capture-media v1.1.2

Weekly downloads
-
License
MIT
Repository
github
Last release
3 days ago

vue-capture-media

vue-capture-media makes it easy to capture media (Microphone, Camera, Video) in your Vue.js apps.

Installation

Use the package manager npm to install vue-capture-media.

npm install vue-capture-media

Usage

Using vue-capture-media is easy:

<template>
    <div>
        <PhotoCapture v-model="imageBase64" />
        <VideoCapture uploadUrl="<example-server-address.com>" v-model="videoUrl" />
    </div>
</template>

<script>
import {PhotoCapture, VideoCapture} from 'vue-capture-media'

export default {
    data(){
        return {
            imageBase64: '',
            videoUrl: '',
        }
    },
    components:{
        PhotoCapture,
        VideoCapture
    }
}
</script>

VideoCapture Component Usage

For the VideoCaptrue component to work correctly, pass an uploadUrl prop for your server. Kindly see a sample server here:

VideoCapture Server Configuration

VideoCapture Component Props

PropValueIsRequiredExample
uploadUrlThe server url to which the component will upload the video totrue'localhost:3000' / 'foo-bar.com'
recordBtnContentcontent for the video record buttonfalse'⬤'
stopBtnContentcontent for the stop recording buttonfalse'◼'
cancelBtnContentbutton for clearing the recorderd video contentfalse'ⅹ'
doneBtnContentbutton to confirm video is fine and handling its urlfalse'✓'

PhotoCapture Component Props

PropValueIsRequiredExample
capturedBtnContentcontent for the image capture buttonfalse'📷'
cancelBtnContentbutton for clearing the captured image contentfalse'ⅹ'
doneBtnContentbutton to confirm image is fine and handling its base64 formatfalse'✓'

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

MIT

1.1.1

3 days ago

1.1.2

3 days ago

1.1.0

8 months ago

1.0.9

11 months ago

1.0.11

10 months ago

1.0.10

10 months ago

1.0.12

10 months ago

1.0.8

12 months ago

1.0.7

12 months ago

1.0.6

12 months ago

1.0.5

12 months ago

1.0.4

12 months ago

1.0.2

12 months ago

1.0.1

12 months ago

1.0.0

12 months ago