使用带有ant设计的"@apollo/client": "^3.0.2"时,我得到一个错误的Cannot add property key, object is not extensible。为了让我的数据在ant设计表中工作,我必须传入从服务器返回的data对象中获得的数组数据。当我试图迭代items数组,并为每个对象添加一个key时,我得到了错误的部分,这样react就不会在控制台中抱怨缺少html的key元素。const items
我想重写background-color类的ant-menu-item-selected属性。默认情况下,它看起来是蓝色的。import { Menu } from 'antd';
//item2 will be rendered with the class 'ant-menu-item-selected