Svelte-Awesome
Awesome SVG icon component for Svelte JS, built with Font Awesome icons. Based on Justineo/vue-awesome
Svelte-Awesome supports Font-Awesome v4.7.0
(icons inbuilt) and v5
(via @fortawesome
npm packages)
A demo is available here
Installation
NPM
$ npm install --save svelte-awesome
Usage
<Icon data={beer}></Icon>
<Icon data={refresh} scale="2"></Icon>
<Icon data={comment} flip="horizontal"></Icon>
<Icon data={codeFork} label="Forked Repository"></Icon>
<Icon label="No Photos">
<Icon data={camera}></Icon>
<Icon name={ban} scale="2" class="alert"></Icon>
</Icon>
<Icon data={faThumbsUp}></Icon>
<script>
import { beer, refresh, comment, codeFork, camera, ban } from 'svelte-awesome/icons';
import { faThumbsUp } from '@fortawesome/free-regular-svg-icons';
</script>