Slot Configuration
One of the handy features of LWC Garden is the ability to fill your slot
s while you are building.
This can be configured in two different places:
- Global
garden.config.js
file - Component level
garden.config.js
file
Global Configuration
/** * @type {import('@lwc-garden/core/types').GardenConfig} */export default { placeholder: true, slots: { default: () => import('example/button'), slot1: () => import('example/clock'), slot2: () => import('example/button'), },}
Read more on the Configuration Page
Component Configuration
/** * @type {import('@lwc-garden/core/types').GardenComponentModule} */export default { name: 'Slot Component Example', slotComponents: { default: () => import('example/button'), slot1: () => import('example/clock'), slot2: () => import('example/button'), },}
Read more on the Component Configuration Page