mercredi 3 octobre 2018

execute content in the if statement inside render

I want to execute all lines inside if statement but i can't

this is my code

  render() {
    return (
{ 
  data.length  > 0 ?
    <Text>Hi</Text>
  : this.testFunction()  <Text>Hello</Text>
           })}

I want to execute (this.testFunction()) and (<Text>Hello</Text>)

thank you

Aucun commentaire:

Enregistrer un commentaire