-
-
Notifications
You must be signed in to change notification settings - Fork 30.5k
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
svg-icon 是否可以通过url地址加载svg图标呢? #2034
Comments
svg 本身是支持的。 https://stackoverflow.com/questions/34097191/using-a-svg-file-in-html-from-a-url 不过你这样做的意义是什么? |
服务端返回的是一个icon的地址,我在想如果用svg图标的地址是否一样可以用svg-icon组件 |
我来实现一下吧。 |
我测了下,使用 url 加载的方式有一个弊端,不能修改 svg 的颜色。 |
把svg源文件中的fill 跟stroke填充颜色去掉的话,应该能修改吧,不能修改颜色也没关系,可以加载就行了 |
Added in #2052 |
多谢裤衩哥 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
类似于img标签通过url连接从网络上加载图片一样
The text was updated successfully, but these errors were encountered: