私のコードは正常に動作しているが、ノードは、このコードを警告している:はTEXTAREA値のコンソール警告を反応
<div id="info">
<p> User:<b> {show.firstName} {show.lastName} </b></p>
<textarea value={show.description}> </textarea>
<p> Adress:<b> {show.address.streetAddress} </b></p>
</div>
警告:
proxyConsole.js:56 Warning: Failed form propType:
You provided a `value` prop to a form field without an `onChange` handler.
This will render a read-only field. If the field should be mutable use `defaultValue`.
Otherwise, set either `onChange` or `readOnly`. Check the render method of `Details`
私が変更された場合
<textarea value={show.description}> </textarea>
<textarea defaultValue={show.description}> </textarea>
<textarea> {show.description}</textarea>
または
iはエラーIf you supply
はdefaultValue on a <textarea>, do not pass children
それは大丈夫ですか?または、私は何か間違っているかもしれません。私はテキストエリアへのハンドラは必要ありません
はい、私は知っていますが、それはタスクによって要求されます – Redair
しかし、なぜdefaultValueを使用するとエラー? – Redair