如何在活动时将“组件”传递到选项卡面板?
请向我解释如何在antd
库中活动时将组件
传递到选项卡面板中?示例组件productshoe,
<Tabs defaultActiveKey="1">
<TabPane tab="productshoe" key="productshoe">
<Productshoe/>
</TabPane>
但会导致错误
Please explain to me how to pass component
into tab panel when active in antd
library? Example component Productshoe
<Tabs defaultActiveKey="1">
<TabPane tab="productshoe" key="productshoe">
<Productshoe/>
</TabPane>
but it makes error
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您在 TabPane 中的
key
与父Tabs
的键不匹配。尽量保持键值相同。如果添加更多选项卡,请保持键值唯一。参考:链接
Your
key
in TabPane doesn't match with the key of parentTabs
. Try to keep the key value same. And keep key values unique if you add more tabs.Reference: Link