Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

null is not an object (evaluating 'this.state.noteArray') #13495

Closed
IsmaelEzequiel opened this issue Apr 13, 2017 · 0 comments
Closed

null is not an object (evaluating 'this.state.noteArray') #13495

IsmaelEzequiel opened this issue Apr 13, 2017 · 0 comments
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@IsmaelEzequiel
Copy link

IsmaelEzequiel commented Apr 13, 2017

Why Im getting this error while I already have my constructor?

` export default class testPoject extends Component {
constructor(props) {
super(props);
this.state = {noteArray: []}
}

render() {

let notes = this.state.noteArray.map((val, key) => {
    return <Note key={key} keyval={key} val={val} deleteMethod={ () => this.deleteNote(key)} />
});

return (
<View style={styles.container}>

        <View style={styles.header}>
            <Text style={styles.headerText}>TODO LIST  </Text>
        </View>

        <ScrollView style={styles.scrollConainer}>

        </ScrollView>

        <View style={styles.footer}>

            <TouchableOpacity style={styles.addButton}>
                <Text style={styles.addButtonText}>
                    +
                </Text>
            </TouchableOpacity>

            <TextInput style={styles.noteInputText}
                placeholder="> Note"
                placeholderTextColor="#FFF"
                underlineColorAndroid="transparent"
                numberOfLines = {3}
            />

        </View>

</View>
);

}`

To have a better look at my code, you can take a look here: https://github.com/IsmaelEzequiel/Sample_React_Native_App/blob/master/index.android.js

@facebook facebook locked as resolved and limited conversation to collaborators May 24, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 18, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

2 participants