antdvue2.x 使用阿里iconfont自定义组件iconfont

时间:2021-08-29 19:08:24   收藏:0   阅读:37
var style = `.icon {
       width: 1em; height: 1em;
       vertical-align: -0.15em;
       fill: currentColor;
       overflow: hidden;
    }`
myutils.loadStyle(style);
var IconFont = {
    name: ‘IconFont‘,
    props: [‘type‘],
    template: `<span><svg class="icon" aria-hidden="true"><use :xlink:href="‘#‘+type"></use></svg></span>`
}

 

原文:https://www.cnblogs.com/Im-Victor/p/15200382.html

评论(0)
© 2014 bubuko.com 版权所有 - 联系我们:wmxa8@hotmail.com
打开技术之扣,分享程序人生!