A small python script that converts svg icons to svelte components. Resulting components have prop style which can be used to assign css classes to them. Styling works the best with tailwind.
git clone [email protected]:benciks/svelte-icon-generator.git
pip install -r requirements.txt
usage: generator.py [-h] -i I [-o O]
Arguments:
After generating the files, you can copy them over to your project and the use is following:
<script>
import ExampleIcon from '$lib/assets/icons/example.svelte';
</script>
<ExampleIcon style="text-blue-600 h-6 w-6" />