前端有道 前端有道
导航
算法
开发
  • Git

    • Git导读
  • 收藏夹 (opens new window)
  • 工具库 (opens new window)
  • netlify Vuepress (opens new window)
  • vercel Vuepress (opens new window)
  • Vuepress2.0 (opens new window)
  • netlify Vuepress2.0 (opens new window)
留言区
娱乐
关于
  • 时间轴
  • 标签
  • 分类

星野

给岁月以文明
导航
算法
开发
  • Git

    • Git导读
  • 收藏夹 (opens new window)
  • 工具库 (opens new window)
  • netlify Vuepress (opens new window)
  • vercel Vuepress (opens new window)
  • Vuepress2.0 (opens new window)
  • netlify Vuepress2.0 (opens new window)
留言区
娱乐
关于
  • 时间轴
  • 标签
  • 分类
  • 基础知识

  • 工程化

  • 组件库

    • 手写el-form表单组件
    • Vue Toast组件开发
    • Vue button组件开发
    • Vue icon组件开发
    • Vue input组件开发
    • Vue message组件开发
    • Vue Popover组件开发
  • CSS

  • ES6-ES12

  • JavaScript

  • Vue2

  • Vue3

  • webpack

  • 浏览器

  • 开发
  • 组件库
星野
2021-5-29
0

Vue icon组件开发

<template>
  <svg class="icon" aria-hidden="true" :class="svgClass">
    <use :xlink:href="`#${icon}`"></use>
  </svg>
</template>
<script>
export default {
  name: 'lcxIcon',
  props: {
    icon: {
      type: String,
      required: true
    },
    svgClass: {
      type: String
    }
  }
};
</script>
<style lang="scss" scoped>
.icon {
  width: 1em;
  height: 1em;
  vertical-align: -0.15em;
  fill: currentColor;
  overflow: hidden;
  color: #999;
}
</style>

#vue
上次更新: 2022/05/09, 06:48:29
Vue button组件开发
Vue input组件开发

← Vue button组件开发 Vue input组件开发→

最近更新
01
图解Git
05-10
02
关于 - 网站错误反馈
05-10
03
关于 - 赞赏❤️的用途
05-10
更多文章>
加入前端有道交流群 | Copyright © 2018-2025 星野 | MIT License
  • 跟随系统
  • 浅色模式
  • 深色模式
  • 阅读模式