[React] 怎么更新组件props上的属性? #3244
Answered
by
janryWang
ytftianwen
asked this question in
Q&A [2.x]
-
问题:怎么更新组件中的props属性 在线地址:复现demo 大佬们这种情况有什么方法处理呢 |
Beta Was this translation helpful? Give feedback.
Answered by
janryWang
Jul 3, 2022
Replies: 2 comments 4 replies
Answer selected by
janryWang
-
你好,试试这种? export default () => {
const [bordered, setBorder] = useState(true);
const form = useMemo(() => {
return createForm();
}, [bordered]);
} 触发表单重新渲染 |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://formilyjs.org/zh-CN/guide/advanced/controlled