vue-icons-lite
v1.1.2
Published
Install NPM
Readme
Vue 3 Icon Component
Installation
Install NPM
npm install vue-icons-liteInstall via yarn
yarn add vue-icons-liteGlobal Vue Usage
import { createApp } from "vue";
import Icon from "vue-icons-lite";
const app = createApp();
app.component("Icon", Icon);
app.mount("#app");Local Usage (Options API)
<script>
import Icon from "vue-icons-lite";
export default {
components: { Icon }
}
</script>Local Usage (Composition API)
<script>
import Icon from "vue-icons-lite";
export degault {
setup() {
return { Icon }
}
}
</script>Example
<template>
<Icon name="photo" size="36"/>
</template>Props
| Name | Type | Default | Description | |-----------|--------|---------|-----------------------------------------------------------------------------| | name | String | null | Icon name. The icon in the public/icons folder should be named the same way | | size | String | 24 | Icon size | | className | String | null | Class for the block in which the icon is located |
About the package
Icon uses the icons located in /public/icons
