YouTubeでReact Nativeに関するチュートリアルを見ました。Reactネイティブリリース手紙がありません
シンプルなストッパーアプリを作りました。 (Android)問題は、リリースビルドでは、文字のいずれかが欠落しています。私はちょうど "こんにちは"を持って、別のシンプルなアプリケーションを構築しようとしました。
画像:
開発ビルド使用してネクサス6(AVD):
リリースLGのG4でビルド(物理):
私にはありませんなぜこれが起こっているか知っている。私は助言と助けに感謝します。
編集:index.android.js:
import React, { Component } from 'react'
import {
AppRegistry,
StyleSheet,
View,
Text,
TouchableHighlight
} from 'react-native'
class flexbox extends Component {
render() {
return (
<View style={styles.container}>
<View style={[styles.header]}>
<View style={[styles.timeWrapper]}>
<Text style={styles.timer}>00:00.00</Text>
</View>
<View style={[styles.buttonWrapper]}>
<TouchableHighlight onPress={() => console.log('Start')} underlayColor="#2ecc71" style={[styles.button, styles.startButton]}>
<Text>Start</Text>
</TouchableHighlight>
<TouchableHighlight onPress={() => console.log('Lap')} underlayColor="#1abc9c" style={[styles.button, styles.lapButton]}>
<Text>Lap</Text>
</TouchableHighlight>
</View>
</View>
<View style={[styles.footer]}>
<Text>Laps</Text>
</View>
</View>
)
}
}
const styles = StyleSheet.create({
container: {
flex: 1
},
header: {
flex: 1
},
footer: {
flex: 1
},
timeWrapper: {
flex: 5,
justifyContent: 'center',
alignItems: 'center'
},
buttonWrapper: {
flex: 3,
flexDirection: 'row',
justifyContent: 'space-around',
alignItems: 'center'
},
timer: {
fontSize: 60,
color: 'black'
},
button: {
borderWidth: 2,
height: 100,
width: 100,
borderRadius: 50,
justifyContent: 'center',
alignItems: 'center'
},
startButton: {
borderColor: '#2ecc71'
},
lapButton: {
borderColor: '#1abc9c'
}
})
AppRegistry.registerComponent('flexbox',() => flexbox)
の例を参照してください時々デバイスが異なる動作を..あなたは、同じデバイス上で両方のリリースとデバッグを試してみて、それかどうかを確認することができます起こる?また、いくつかのコードを提供することで、私たちが問題を特定するのを助けることができます – atlanteh
私は自分の電話にデバッグをインストールしようとします。 – shabenda
ADBは正しいですか? – shabenda