Ich möchte ein Video von der URL mit Expo SDK für die Reaktion native.Ich lese die SDK, aber ich kann nicht verstehen, wie es funktioniert. Here is link for expo sdk video docs.React-Native Video abspielen mit Expo SDK
Hier ist mein Code
import React from 'react';
import { StyleSheet, Text, View,Button } from 'react-native';
import { Video } from 'expo';
export default class App extends React.Component {
_handleVideoRef = component => {
}
onPlayPressed(){
}
render() {
return (
<View style={styles.container}>
<Expo.Video
source = {{uri :'url for video'}}
ref={this._handleVideoRef}
/>
<Text>Open up App.js to start working on your app! </Text>
<Button onPress={this.onPlayPressed.bind(this)} title = "Play"/>
</View>
);
}
}
const styles = StyleSheet.create({
container: {
flex: 1,
backgroundColor: '#fff',
alignItems: 'center',
justifyContent: 'center',
},
});
Doc sagt Video-Tag arbeitet als Inline aber ich bin nicht sicher, warum es nicht Video oder etwas mehr spielen benötigt wird.
Vielen Dank für jede Hilfe
Ich habe es geändert, wie Sie sagten, aber es spielt kein Video. – sanman