title: How to handle multi input in react native generically?
body: <p>I'd like to know why this code doesn't work :</p>
  
  <pre><code>&lt;TextInput 
    style={style.inputLogin} 
    onChangeText={this.handleInputChange} 
    value={this.state.login} 
  /&gt;
  </code></pre>
  
  <p>with the function : </p>
  
  <pre><code>  handleInputChange = (event) =&gt; {
      console.log(event.target.name);
      this.setState({
        [name]: value
      });
      console.log("name =&gt; ", [name]);
      console.log("value =&gt; ", value);
    }
  </code></pre>
  
  <p>I tried many things but i can't get the targeted form.
  Should I make one function for each input ? seems to be stupid :/
  event only contains the value of the form.
  Sure I could do this :</p>
  
  <pre><code> &lt;TextInput 
    style={style.inputLogin} 
    onChangeText={(value) =&gt; this.setState({value})) 
    value={this.state.login} 
  /&gt;
  </code></pre>
  
  <p>But this is not what I am looking for. I would like something more generic that works for every input</p>
  
  <p>Please help me ;)</p>