-
Notifications
You must be signed in to change notification settings - Fork 340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Icon不显示问题 #343
Comments
@sorrycc 按照文档在dva项目中创建.roadhogrc.js文件并配置svg图标路径,但是引用svg图标的时候还是报错,我的引用是: <Item key="4" value="scan" icon={<Icon type={require('../assets/icons/scan.svg')} size="xs" /> 刚学习dva,水平很差,麻烦前辈了,谢谢 |
问题同 #345 |
在项目下安装svg-sprite-loader@0.3.1即可解决问题; 项目的pacage.json相关部分代码如下: "antd-mobile": "^1.6.3", |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
dva项目使用antd-mobile,引用src/assets/中的svg图标的时候,会报错:
Icon props.type is invalid, have you set svg-sprite-loader correctly? see https://goo.gl/kN8oiw
引入svg-sprite-loader后还是报这个错。
dva项目需要怎么配置svg-sprite-loader?如何正确使用svg图标?谢谢
The text was updated successfully, but these errors were encountered: