Closed randomiser closed 10 months ago
You can extend a component.
// in your src/lib/MyAcademicCap.svelte
<script>
import { AcademicCap } from 'svelte-heros-v2';
</script>
<AcademicCap variation="solid" size="50"/>
And you can use it:
<script>
import MyAcademicCap from '$lib/MyAcademicCap.svelte';
</script>
<MyAcademicCap />
I can see the benefits of using a config file. I will see if it works.
Description
I've been looking at this upcoming PR:
https://github.com/shinokada/svelte-heros-v2/pull/21
Thinking it would be useful to be able to control the solid | outline | mini defaults at a global level rather than having to apply "solid" to every image.
Something like this could work:
SvelteHeroes.defaultVariation = SvelteHeroes.solid;
Likewise setting the size globally could also be useful.
Cheers, Matt
Additional Information
No response