Slot

See how slots can help you take control of your content.

In our content system, slots are placeholders for content. They define where content goes and what type of content you can use.

Slot

Each slot is associated with a specific component that defines its structure. While components are generic, slots are more specific. They represent personalizable elements in your application, such as a hero section, an announcement bar, or a banner on the checkout page.

Component

To create a slot, you must first specify some basic information about the slot and then select the component that defines its content structure. If you have not created a component yet, you need to create one before creating a slot.

After that, you need to define the default content, as explained below.

Default content

Traditionally, content management systems have focused on static content, delivering the same message to all visitors regardless of their context.

In contrast, as a Personalization Management System (PMS), we focus primarily on delivering personalized experiences to different users. This includes support for static content, but only as a fallback. We refer to this as the default content.

Croct's mascot neutral
Why not call it static content then?

We do not use the term static content because you can include dynamic values in the default content. So, it is not necessarily static.

To ensure your application has content to display, we require you to define default content for each slot. This content is used in the following situations:

  • Lack of personalized content
    When a user does not fall into any of the experiences.

  • Lack of localized content
    When an experience has no content for a specific locale.

  • Static rendering
    When the application explicitly requests static content (e.g. pre-rendering).

  • Unexpected errors
    In the event of unexpected errors during content retrieval.

The default content supports all the features described in the definition reference, including dynamic values and localization.

Localization

Localization is the process of adapting content to a specific locale. For companies with a global presence, it is a must-have feature that allows them to deliver personalized experiences in different languages.

Localization

When you create a slot, you have to define default content for every required locale specified in your workspace. You can also provide default content for any optional locale. In case you do not provide default content for a specific locale, the content for the default locale is used instead.

Versioning

Slots are versioned independently from components to ensure that you can make changes to a component without affecting the content of existing slots.

We handle versioning automatically for you, just like with components. Whenever you make changes to a component that affect the content structure in an incompatible way, we create a new version of the component to ensure everything keeps working properly.

This is an overview of the slot versioning process:

  1. You modify the component schema to make the desired changes.

  2. We create a new version with the updated schema and keep the old version untouched.

  3. While you adjust the content of affected slots or experiences, we continue to serve the old version to your application.

  4. Lastly, you bump the version number and apply the necessary changes to your application.

To assist you with step 3, we indicate the exact slots that require your review whenever you make a breaking change:

Slot impact alert

It is important to note that this alert is just a reminder. You can take your time to review and update as needed — everything will continue to work as usual.

Another way to identify which slots need your attention is to look at the version number next to each slot in the slot list:

Slot list

For reference, these are the step-by-step instructions to update a slot:

  1. Click Slots in the left sidebar.

  2. Find the slot you want to update and click it.

  3. Click the content with the warning indicator.

  4. Apply the necessary changes and click Save.

  5. Repeat the last two steps for every content with the warning indicator.

  6. Click Save in the bottom right of the page to finish.

After you have updated the slot, you will see a reminder to increase the version number in your application code:

Version bump alert

This step is only necessary if you are explicitly specifying the slot version in your application code. Until you do so, the application will continue to use the content of the specified version.

Croct's mascot buggy
What is the risk of not specifying the version?

Not specifying means you are using the latest version of the slot, so any changes will take effect immediately, potentially breaking your application.

Once you have saved your changes, you will see that the version number in the selector at the top right of the page has increased. You can still access and edit previous versions of the slot by selecting them in the version selector.

Last but not least, if the affected slot is used in an experience, you will also need to reflect the changes in the experience's content.

Further reading

For more on slots and related topics, check out the following resources: