** I have some issue when adding just Button !!**
and in the app that's the error
java.lang.string cannot be cast to com.facebook.react.uimanager.accessibility DelegateUtil$accessibilityRole
my simple code
import React, { Component } from "react";
import { StyleSheet, TextInput, View, Button, Text } from "react-native";
export default class App extends Component {
state = {
placeName: ""
};
placeNameChangeHandler = val => {
this.setState({
placeName: val
});
};
onPressLearnMore = () => {
alert("Pressed");
};
render() {
return (
<View style={styles.container}>
<Button
onPress={this.onPressLearnMore}
title="Learn More"
color="#841584"
/>
<TextInput
style={{
width: 300,
borderBottomWidth: 1,
borderBottomColor: "#333"
}}
placeholder="Enter Name.."
value={this.state.placeName}
onChangeText={this.placeNameChangeHandler}
/>
</View>
);
}
Button
your code works normally?