Reputation: 428
I created this basic Svelte example following the official tutorial.
App.svelte
:
<script>
import PageWrapper from './PageWrapper.svelte'
</script>
<PageWrapper>
<div name="cover">
My cover
</div>
</PageWrapper>
PageWrapper.svelte
:
The cover is:
<slot name="cover">no cover</slot>
The result is always:
The cover is: no cover
Why? What am I doing wrong?
Upvotes: 0
Views: 85