[功能请求] 封装 Icon 组件后,也能正常检测到本地图标
作者: haohaio创建于 2024年8月17日更新于 2026年6月2日
标签type(enhancement)
□ 背景情况
图标 图标 图标
时间轴 : 从“ react” 导入类型{组件Props}; 从 “ umi ” 导入{ 图标} ;
const MyIcon: react.FC <componentProps <typeof Icon=(道具){{ 返回 <Icon宽="1em"高="1em"填充="当前颜色"{.props}/>;
- ;
导出默认 MyIcon ;
时间轴 :
< MyIcon 图标="本地: home" className="text-[12px] text-[red]" />□提议
QQ 图标 QQ 图标 : { 包括: ['local: *']} QQ.
内容来源: umijs/umi