0.3.1-beta • Published 1 month ago
expo-reanimated-av-player-extend v0.3.1-beta
Installation
First you have to follow installation instructions of:
- react-native-reanimated v2
- react-native-gesture-handler v2
- expo-screen-orientation
- react-native-safe-area-context
- expo-av
- lottie-react-native no support web
yarn add expo-reanimated-av-player
Example usage
import VideoPlayer from 'expo-reanimated-av-player';
import { useSharedValue } from 'react-native-reanimated';
export const Example = () => {
const videoHeight = useSharedValue(0);
const isFullScreen = useSharedValue(false);
return (
<VideoPlayer
source={videoInfo.source}
headerBarTitle={`fullscreen title`}
onToggleAutoPlay={(state: boolean) => {
console.log(`onToggleAutoPlay state: ${state}`);
}}
videoDefaultHeight={VIDEO_DEFAULT_HEIGHT}
videoHeight={videoHeight}
resizeMode="cover"
isFullScreen={isFullScreen}
onTapBack={() => {
console.log('onTapBack');
}}
onTapMore={() => {
console.log('onTapMore');
}}
/>
);
};
Features
- 100% written in
TypeScript
. - 100% built upon
react-native-reanimated
andreact-native-gusture-handler
. - Support gestures switch full screen.
- Support double tap seek to back or ahead.
- ...
Configuration
The <VideoPlayer/>
component has the following configuration properties:
0.3.1-beta
1 month ago
0.3.0-beta
9 months ago
0.3.0-beta-1
9 months ago
0.2.9
9 months ago
0.2.8
9 months ago
0.2.7
9 months ago
0.2.6
10 months ago
0.2.5
10 months ago
0.2.4
10 months ago
0.2.3
10 months ago
0.2.2
10 months ago
0.2.1
10 months ago