react-native-webview-video
v0.2.8
Published
react-native-webview-video is a React Native library that provides a Video component that renders media content such as videos with custom controls for react-native and react-native-web. Support Youtube and Vimeo.
Downloads
36
Maintainers
Readme
React Native Webview Video
React Native library that provides a Video component that renders media content such as videos with custom controls for react-native and react-native-web. Support Youtube and Vimeo.
When use react-native-web please guild setup in https://www.npmjs.com/package/@chainplatform/react-native-web-webview
Install
npm install react-native-webview-video --save
or
yarn add react-native-webview-video
Usage
Note: Set useRemote={true} if export web as mini app.
import React from 'react';
import {StyleSheet} from 'react-native';
import Video from 'react-native-webview-video';
class App extends React.Component {
render() {
return (
<View style={{flex:1}}>
<Video
videoId={"wJ1rCGK06bk"}
videoType={"youtube"}
useRemote={false}
poster={"https://i.imgur.com/jsaRvR3.png"}
/>
</View>
);
}
}