textarea 组件 #8
yangxiaolu1993
started this conversation in
General
Replies: 0 comments 3 replies
-
已修改完成 |
Beta Was this translation helpful? Give feedback.
0 replies
-
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
1、使用 change 事件进行对 value 赋值,输入内容出错
<TextArea defaultValue={value1} change={change} /> const [value1, UpdateValue1] = useState('') const change = (value: string, event: Event) => { UpdateVale1(value) }
2、新增 emit 事件 demo
3、maxLength 设置为 ‘-1’ 时,则失效
4、defaultValue 设置的初始值的长度大于 maxlength 设置的长度
<TextArea defaultValue={value2} limitshow maxlength="2" /> const [value2, UpdateValue2] = useState('异步文本')
Beta Was this translation helpful? Give feedback.
All reactions