ant-design / ant-design-icons

⭐ Ant Design SVG Icons
https://ant.design/components/icon/
MIT License
939 stars 577 forks source link

fix(icons-react): use HTMLAttributes instead of HTMLProps #629

Closed vagusX closed 3 months ago

vagusX commented 3 months ago

related to


Reference from gpt-4

React-specific attributes that are included in React.HTMLProps but not in React.HTMLAttributes include:

ref: This is a special attribute that can be used to get a reference to the underlying DOM element or the instance of a class component. It's useful for direct manipulation of DOM elements.

key: This is a special attribute that helps React identify which items have changed, are added, or are removed in lists. It's important for efficient re-rendering of lists.

vagusX commented 3 months ago
wzc520pyfm commented 3 months ago
  • @ant-design/icons@5.3.2

Will there be an update to version 4.x? Because @types/react also relased version 17.0.78, @ant-desgin/icon@4.x will also report this error.