Vue component for Cloudflare Stream
Vue component for Cloudflare Stream.
Note that this is not an official component.
- Vetur autocomplete for props and events
First install stream-vue
:
pnpm add stream-vue
# or
yarn add stream-vue
npm install stream-vue --save
<template>
<VideoStream controls src="YOUR_VIDEO_ID_OR_SIGNED_URL">
</template>
<script>
import { VideoStream } from 'stream-vue'
export default {
components: { VideoStream }
}
</script>
To use with Nuxt 2, make sure to add the following to your nuxt.config.js
:
vue: {
config: {
ignoredElements: ['stream']
}
}
See @cloudflare/stream-react for more props and events.
This is just a Vue fork of @cloudflare/stream-react.
This has been developed to suit my needs but additional use cases and contributions are very welcome.
MIT License - Copyright © Daniel Roe