We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
H5
https://github.com/gyf30827/taro-demo 浏览器版本: chrome ,版本 103.0.5060.134(正式版本) (x86_64) 使用框架: React
1.启动demo项目后 2.在输入框内输入超过3个字符
只显示3个字符
输入几个显示几个
👽 Taro v3.4.14 Taro CLI 3.4.14 environment info: System: OS: macOS 11.5.1 Shell: 5.8 - /bin/zsh Binaries: Node: 16.15.1 - ~/.nvm/versions/node/v16.15.1/bin/node Yarn: 1.22.19 - /usr/local/bin/yarn npm: 8.11.0 - ~/.nvm/versions/node/v16.15.1/bin/npm npmPackages: @tarojs/components: 3.4.14 => 3.4.14 @tarojs/mini-runner: 3.4.14 => 3.4.14 @tarojs/plugin-framework-react: 3.4.14 => 3.4.14 @tarojs/react: 3.4.14 => 3.4.14 @tarojs/runtime: 3.4.14 => 3.4.14 @tarojs/taro: 3.4.14 => 3.4.14 @tarojs/webpack-runner: 3.4.14 => 3.4.14 babel-preset-taro: 3.4.14 => 3.4.14 eslint-config-taro: 3.4.14 => 3.4.14 react: ^17.0.0 => 17.0.2
demo内受控逻辑代码
The text was updated successfully, but these errors were encountered:
3.5+ 版本中会在 input 组件内主动修改输入值控制 value,低版本中遇到相同值不受控制情况需要获取 input 组件实例修改 value 值避免控制失效。
在 react 组件中相同的 value 不会触发组件更新,这同样会导致 input 组件失去控制,所以在此情况下也需要手动触发组件更新。
Sorry, something went wrong.
貌似在微信小程序也不受控
可以参考这个临时解决方案:#2642
No branches or pull requests
相关平台
H5
复现仓库
https://github.com/gyf30827/taro-demo
浏览器版本: chrome ,版本 103.0.5060.134(正式版本) (x86_64)
使用框架: React
复现步骤
1.启动demo项目后
2.在输入框内输入超过3个字符
期望结果
只显示3个字符
实际结果
输入几个显示几个
环境信息
demo内受控逻辑代码
The text was updated successfully, but these errors were encountered: