Svelte component for Heroicons.
npm i -S @martinse/svelte-heroicons
<script>
import Heroicon from '@martinse/svelte-heroicons';
import {heart as solidHeart} from '@martinse/svelte-heroicons/dist/solid';
import {heart as outlineHeart} from '@martinse/svelte-heroicons/dist/outline';
</script>
<Heroicon icon={outlineHeart}/>
<Heroicon icon={outlineHeart} size="2em"/>
<Heroicon icon={solidHeart} size="3em" class="red"/>
<style>
:global(.red) {
color: red;
}
</style>
Will render:
In order to build new versions of this package, there some prerequisites to be installed, and some commands to execute. The build process is executed within a Docker container.
task build
Building the package is composed of two stes:
task generate-icon-data
task build-npm-dist
package.json
task publish
Update the HEROICONS_VERSION
variable in Taskfile.yml
and rebuild the Docker container + build/publish the NPM
package.
/dist
path when importing solid or outlineTaskfile.yml
and package.json
automaticallytask publish