1. Component Guide
  2. Form radio button
  3. Conditional
Form radio button example

Conditional

How it looks (preview)

You’ll need to prove your identity using Government Gateway
You’ll need to prove your identity using GOV.UK Verify

How to call this example

<%= render "govuk_publishing_components/components/radio", {
  name: "radio-group-conditional",
  id_prefix: "conditional",
  items: [
    {
      value: "government-gateway",
      text: "Use Government Gateway",
      conditional: "You’ll need to prove your identity using Government Gateway"
    },
    {
      value: "govuk-verify",
      text: "Use GOV.UK Verify",
      conditional: "You’ll need to prove your identity using GOV.UK Verify"
    }
  ]
} %>