小编nar*_*han的帖子

运行adb时出错:运行应用程序时出错.错误:活动未启动,无法解析Intent

嗨,我正在尝试在我的反应本机项目上运行'yarn android'.并且遇到以下错误:

yarn android v0.27.5
$ react-native-scripts android
10:37:45 AM: Starting packager...
10:39:34 AM: Starting Android...
10:39:37 AM: Packager started!

To view your app with live reloading, point the Expo app to this QR code.
You'll find the QR scanner on the Projects tab of the app.

    <QR CODE>                                                  

Or enter this address in the Expo app's search bar:

  exp://172.19.29.31:19000

Your phone will need to be on the same local network as this computer.
For links to install the Expo …
Run Code Online (Sandbox Code Playgroud)

android react-native expo create-react-native-app

11
推荐指数
1
解决办法
2880
查看次数

如何确定视频是否刚刚使用 expo.video 完成?ReactNative/Expo.io

例如,如果我有组件:

import React, { Component } from 'react';
import { Video } from 'expo';
let styles = require('../stylesheet.js');
export default class Player extends Component {
  render(){
    return(
     <Video
      ref={this._handleVideoRef}
      source={require(//file)}
      rate={1.0}
      volume={1.0}
      muted={false}
      useNativeControls
      resizeMode="cover"
      shouldPlay
      style={styles.player} />
      )
  }
}
Run Code Online (Sandbox Code Playgroud)

我在文档(https://docs.expo.io/versions/latest/sdk/av.html)中看到使用“playbackstatus.didJustFinish”和 onPlaybackStatusUpdate 但他们的例子对我来说没有多大意义。谁能告诉我如何使用我的代码确定视频是否已结束?

javascript react-native expo

5
推荐指数
1
解决办法
2631
查看次数