Component composition Named slots • Svelte Tutorial
Component composition Named slots • Svelte Tutorial
In this video we're going to learn how to compose our components using slots in Svelte ▶️
2 Answers 2 This is not possible right now The only slot that can be assigned without naming it, is the default slot You can't have two
svelte pass props to slot The contents of a Svelte component can be passed through slots Svelte supports default slots, named slots, and slots that pass data back to the slotted content
svelte slot props To create a slot in Svelte, use the slot element within a component's template The slot element is a placeholder for the content you will pass
Regular
price
183.00 ₹ INR
Regular
price
183.00 ₹ INR
Sale
price
183.00 ₹ INR
Unit price
/
per