Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Slots

Security covered Under active development 16 sites

The Slots module allows you to create customizable content placeholders throughout your Drupal site. Content editors can then add various pieces of content into these slots based on specific conditions, without needing to alter the site's configuration. This provides a flexible way to manage content like calls-to-action or promotional banners across different areas and content types.

The Slots module provides "slot" placeholders that can be placed anywhere on your site — via Block UI, Layout Builder, Views, Paragraphs, or directly in Twig — and lets content editors "push" content into them based on configurable conditions, without that content needing to live in your site's configuration.

Typical use cases:

  • A placeholder in a layout where editors can drop in a CTA for a specific node type
  • A piece of content in a default layout that you don't want exported to config — place a slot instead and add the content later
  • Flexible CTAs inside Paragraphs, controlled entirely by conditions
  • Content above a view that editors manage independently of the view's configuration

Features

  • "Slot" placeable via Block UI or Layout Builder, with a configurable slot identifier and cardinality
  • Content is matched to slots via the reusable conditions condition system — combine the "Slot" condition with any other condition (request path, language, role, ...)
  • Not limited to blocks — any entity type can be made slot-aware by adding a "Slots" field
  • Sub-modules for Views integration (slots_views), Paragraphs (slots_paragraphs), and Twig (slots_twig, providing a slot() Twig function)
  • Drag-and-drop weight ordering for content competing for the same slot

Requirements

Getting started

Place a "Slot" via Block UI or Layout Builder and give it a slot identifier. Then add a "Slots" field to the entity type you want to use as slot content (e.g. a block content type), enable "This content shall be displayed in slots", and add a "Slot" condition with the matching identifier — the content will now appear wherever that slot is placed.

Drupal 10–11

Ask your assistant about Slots

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
13
Tracked since
May 2024
Latest release
6 months ago
Releases (12 mo)
2 ▼ from 7
Maintenance
Slowing

Release Timeline

Releases

Version Type Core PHP Release date
1.0.0-alpha2 Pre-release 10–11 May 15, 2024
1.0.0-alpha1 Pre-release 10–11 May 15, 2024
1.x-dev Dev 10–11 May 14, 2024