react-covideo-embed v1.0.40
react-covideo-embed
Covideo platform as an embeddable React component.
Installation
npm install react-covideo-embed
PeerDependencies
This package has peer dependencies on react
and react-dom
version 16. Please ensure that you have these installed in your project.
Usage
Here’s a basic example of how to use react-covideo-embed in a React component:
import React from 'react';
import { CovideoEmbed } from 'react-covideo-embed';
const MyApp = () => {
return (
<div>
<CovideoEmbed />
</div>
);
};
export default MyApp;
Demo
Explore the capabilities of react-covideo-embed through our Demo Project. This repository serves as a practical example to understand how different props and configurations can be implemented. To run the demo locally, please follow the instructions available in the project’s README.
Props
apikey
- Type:
string
- Description: Used for tracking the origin of requests from this npm module.
token
(optional)
- Type:
string
- Description: JWT token from Covideo. If provided, the module's login/logout pages are disabled. Without it, users will need to log in through the module's login page.
env
(optional)
- Type:
'sandbox'
|'production'
- Description: Determines which Covideo environment to target.
- Default:
'sandbox'
onVideoInsert
(optional)
- Type: function
- Description: Callback triggered when a video is inserted.
- Parameters:
shareData
: Object containing the URL and HTML of the inserted video.url
:string
- The URL of the inserted video.thumbnail
:string
- The HTML of the thumbnail of the inserted video.image
:string
- The URL of the thumbnail of the inserted video.html
:string
- The HTML representation of the inserted video.token
:string
- The auth token used to fetch the shareData.
onVideoInsertError
(optional)
- Type:
function
- Description: Callback triggered when there is an error inserting a video.
- Parameters:
error
:unknown
- The error occurred during video insert.
onRecordButtonClick
(optional)
- Type: function
- Description: Callback triggered when the record button is clicked.
- Parameters:
data
: Object containing the data for recording a video.token
:string
- The auth token.
onUploadButtonClick
(optional)
- Type: function
- Description: Callback triggered when the upload button is clicked.
- Parameters:
data
: Object containing the data for uploading a video.token
:string
- The auth token.
hideFeatures
(optional)
- Type:
Array<Feature>
Description: Determines which Covideo features to hide. Acceptable values are as follows:
insert
recordScreen
recordBoth
recordCam
upload
trim
merge
wheelsTV
voiceover
quickshare
folder
landingPage
CTA
reactions
aiAssist
lesa
multiLocation
APIs/Functions
logoutCovideo()
- Type:
function
- Description: Log out from Covideo and clear local storage entries associated with Covideo. To reflect the logout status, the CovideoEmbed component should be re-rendered after this function is called.
Author
This package is maintained by Covideo.
6 months ago
5 months ago
5 months ago
6 months ago
6 months ago
4 months ago
5 months ago
5 months ago
5 months ago
2 months ago
3 months ago
3 months ago
3 months ago
2 months ago
2 months ago
5 months ago
2 months ago
3 months ago
5 months ago
6 months ago
6 months ago
6 months ago
6 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
7 months ago
10 months ago
10 months ago
10 months ago
11 months ago
11 months ago
11 months ago
10 months ago
11 months ago
11 months ago
11 months ago
12 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
2 years ago
2 years ago
1 year ago
1 year ago
1 year ago
2 years ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago