1. Collections Component Guide
  2. Error alert
  3. With data attributes
Error alert example

With data attributes

How it looks (preview)

How to call this example

<%= render "govuk_publishing_components/components/error_alert", {
  message: "Message to alert the user to a unsuccessful action goes here",
  description: "A further description",
  data_attributes: {
    tracking: "GTM-123AB"
  }
} %>