setFiledState未生效 #1541
Answered
by
janryWang
zhangcong25
asked this question in
Q&A [2.x]
setFiledState未生效
#1541
-
复现地址:https://codesandbox.io/s/compassionate-dawn-c6i98?file=/App.tsx actions.setFieldState("EventNames", (state) => {
console.log("state", state);
state.dataSource = [{ label: "我是选项", value: 1 }];
state.setDataSource([{ label: "我是new", value: 1 }]);
}); setFieldState设置后,页面Select组件选项没有重新渲染 |
Beta Was this translation helpful? Give feedback.
Answered by
janryWang
Jun 2, 2021
Replies: 1 comment 1 reply
-
antd的组件不支持dataSource属性,需要你自己做映射 |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
janryWang
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
antd的组件不支持dataSource属性,需要你自己做映射