iconfont_convert 1.0.0 copy "iconfont_convert: ^1.0.0" to clipboard
iconfont_convert: ^1.0.0 copied to clipboard

A library to generate Flutter IconData Class from www.iconfont.cn

iconfont-convert Pub #

帮助你从 www.iconfont.cn 生成 IconData

支持多个 iconfont 项目

可自动在 pubspec.yaml 中注册字体

安装 #

在项目中安装(推荐) #

pubspec.yaml 中添加

dev_dependencies:
  iconfont: ^1.0.0

运行方式

flutter packages pub run iconfont_convert

全局安装 #

flutter pub global activate iconfont_convert

运行方式

iconfont-convert

参数 #

-c  --config     config file path
                 (defaults to "pubspec.yaml")
-h, --help       help

使用 #

pubspec.yaml 中添加配置

# pubspec.yaml
iconfont:
  - icons:
    - url: //at.alicdn.com/t/c/font_3892650_94qckhszrmg.css
      icon_name: test_icons
      icon_class: TestIcons
    font_assets_path: assets/iconfont/
    icon_class_path: lib/icons/

运行 iconfont-convert

或者使用独立独立配置文件 iconfont.yaml

# iconfont.yaml
- icons:
  - url: //at.alicdn.com/t/c/font_3892650_94qckhszrmg.css
    icon_name: test_icons
    icon_class: TestIcons
  font_assets_path: assets/iconfont/
  icon_class_path: lib/icons/

运行 iconfont-convert --config iconfont.yaml

常见问题 #

  1. iconfont command not found

感谢 #

4
likes
0
pub points
53%
popularity

Publisher

verified publisherwkan.xyz

A library to generate Flutter IconData Class from www.iconfont.cn

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

args, flutter, http, path, yaml

More

Packages that depend on iconfont_convert