Define Slots
// src/mock-server/mock-data/slots.ts
import { cmsParagraphComponent } from '@valantic/spartacus-mock';
import { Occ } from '@spartacus/core';
export const customSlot = (): Occ.ContentSlot => {
return {
slotId: 'testSlot', // use same slotId as an existing slot to overide the default slot
slotUuid: 'testSlot1234',
position: 'TestSlot', // use an existing position to add your custom components to that slot
name: 'My Test Slot',
slotShared: true,
components: {
component: [cmsParagraphComponent('Hello World!')],
},
};
};
export const customSlots = (): Occ.ContentSlot[] => {
return [customSlot()];
};Last updated