Add an id attribute to heading and CTA components

Created on 16 September 2025, 26 days ago

Problem/Motivation

In order to create anchor links to content, the components need an id attribute. We should automatically add this, taking into account that:

  1. It must be unique (if a page has two headings with the same wording, they must have different ids)
  2. Special characters should be stripped
  3. The id should not be too long (max 20 chars?)
Feature request
Status

Active

Version

1.0

Component

Templates/PHP

Created by

🇦🇺Australia pameeela

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024