Skip to content

Icon 图标

字体图标基于阿里巴巴矢量图标库,使用font-class 引用的方式,建议从项目生成代码文件下载到本地使用。

基本使用

ts
// 全局引入从iconfont.cn下载的CSS
import '/static/xxx/iconfont.css';
html
<be-icon name="plus-circle"></be-icon>

INFO

本质上就是文本,能够设置文本相关样式。

API

Props

属性名说明类型默认值
fontFamily阿里巴巴图标库项目配置的 FontFamilystringiconfont
prefix阿里巴巴图标库项目配置的 FontClass 前缀stringicon-
name阿里巴巴图标库项目配置的 FontClass 名string-