关于 Icon Kit
一个为美食相关项目精心设计的 SVG 图标库
图标预览
Burger
Pizza
Coffee
Knife
安装
npm
npm install icon-kityarn
yarn add icon-kitpnpm
pnpm add icon-kit使用方法
React
import { Burger, Pizza, Coffee } from 'icon-kit'
function App() {
return (
<div>
<Burger size={32} color="#ff6b6b" />
<Pizza size={24} color="#4ecdc4" />
<Coffee strokeWidth={1.5} />
</div>
)
}Vue
<template>
<Burger :size="32" color="#ff6b6b" />
<Pizza :size="24" color="#4ecdc4" />
<Coffee :stroke-width="1.5" />
</template>
<script setup>
import { Burger, Pizza, Coffee } from 'icon-kit'
</script>组件属性
| 属性 | 类型 | 默认值 | 描述 |
|---|---|---|---|
| size | number | 24 | 图标尺寸(像素) |
| color | string | 'currentColor' | 图标颜色 |
| strokeWidth | number | 2 | 描边宽度 |
| className | string | - | 自定义 CSS 类名 |
贡献
欢迎贡献新的图标!请查看 贡献指南 了解详情。
# Fork 项目
git clone https://github.com/SongFuZhen/icon_kit.git
cd icon_kit
npm install
npm run dev许可证
MIT License - 可自由使用于个人和商业项目。