carbon-components-svelte/tests/Breakpoint.test.svelte
Eric Liu 18c6f03224
Fix TypeScript definitions; function declarations should be typed as accessors, not props (#740)
* chore(deps-dev): upgrade svelte to v0.8.1

* chore: regenerate types to correctly type function declarations

* test: fix svelte-check warnings
2021-07-10 09:00:57 -07:00

16 lines
305 B
Svelte

<script lang="ts">
import { Breakpoint } from "../types";
import { BreakpointSize } from "../types/Breakpoint/Breakpoint";
let size: BreakpointSize;
</script>
<Breakpoint
bind:size
let:size="{currentSize}"
on:match="{(e) => {
console.log(e.detail);
}}"
>
{currentSize}
</Breakpoint>