2
0
mirror of https://github.com/iconify/iconify.git synced 2024-10-23 17:12:03 +00:00
iconify/components/svelte/tests/api/fixtures/ChangeProps.svelte
2022-05-12 22:39:56 +03:00

25 lines
390 B
Svelte

<script>
import Icon from '../../../';
export let icon;
export let expose;
export let onLoad;
const props = {
icon
};
$: {
expose(swap);
}
function swap() {
props.hFlip = true;
props.style = {
color: 'red'
}
}
</script>
<Icon {...props} on:load={event => {
onLoad?.(event.detail.icon)
}} />