Skip to content

Commit

Permalink
Prevent toast on initial docs page load
Browse files Browse the repository at this point in the history
  • Loading branch information
kbrgl committed Jun 30, 2023
1 parent 58fe5a0 commit 32e5482
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/www/Examples.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
import Copy from './Copy.svelte';
import examples, { type Example } from './examples';
let selected: Example['title'] = 'Success';
$: examples.find((eg) => eg.title === selected)!.action();
let selected: Example['title'] | null = 'Success';
</script>

<div class="grid grid-cols-2 md:grid-cols-3 gap-4 rounded-xl mb-5">
Expand All @@ -19,6 +17,9 @@
id={example.title}
name="examples"
value={example.title}
on:change={() => {
example.action();
}}
bind:group={selected}
/>
<span class="mr-1">{example.emoji}</span>
Expand Down

1 comment on commit 32e5482

@vercel
Copy link

@vercel vercel bot commented on 32e5482 Jun 30, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.