iconfont-cli / taro-iconfont-cli

在Taro框架中使用iconfont图标,支持多端,支持多色彩,不依赖字体。
MIT License
355 stars 49 forks source link

【h5】“React”指 UMD 全局,但当前文件是模块。请考虑改为添加导入。ts(2686) #26

Open ruofeng086 opened 4 years ago

ruofeng086 commented 4 years ago

image

ruofeng086 commented 4 years ago

image

fwh1990 commented 4 years ago

请问下taro的版本

ruofeng086 commented 4 years ago

3.0.0-rc6

---原始邮件--- 发件人: "原罪"<notifications@github.com> 发送时间: 2020年7月7日(周二) 凌晨0:30 收件人: "iconfont-cli/taro-iconfont-cli"<taro-iconfont-cli@noreply.github.com>; 抄送: "ruofeng086"<ruofeng168@qq.com>;"Author"<author@noreply.github.com>; 主题: Re: [iconfont-cli/taro-iconfont-cli] 【h5】“React”指 UMD 全局,但当前文件是模块。请考虑改为添加导入。ts(2686) (#26)

请问下taro的版本

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

fwh1990 commented 4 years ago

taro 2.0的全局使用Taro,到3.0应该都切换到React了,需要适配一下

fwh1990 commented 4 years ago

28

fwh1990 commented 4 years ago

Hello, taro-iconfont-cli@next已经发布,欢迎使用,唯一需要变更的就是usingComponent

// pages/**/index.config.js

import { useIconFont } from '../../components/iconfont/helper';

export default {
  usingComponents: Object.assign(useIconFont()),
}

不算最好的方案,所以正式版先不发布。有什么更好的建议,欢迎随时反馈