I have the following render function, in which I'm getting a warning
"warning: Each child in a list should have a unique "key" prop."
What is the problem? is it true to write key for each tag?
render() {
return (
[ <h1>Update Post</h1>,
<form>
<div >
<label>title</label>
<input type="text" value={this.state.title} onChange={this.handleTitleChange} />
</div>
<div >
<label>body</label>
<input type="text" value={this.state.body} onChange={this.handleBodyChange} />
</div>
<div >
<label>userId</label>
<input type="text" value={this.state.userId} onChange={this.handleUserIDChange} />
</div>
<div >
<input type="button" value="Update post" onClick={this.handleUpdatePost} />
</div>
</form>
]
);
}