List example

Ordered list with numbers

This is an ordered list with the numbers visible.

How it looks (preview)

  1. Tony’s Chocolonely
  2. Cherry Ripe
  3. Snickers
  4. Chomp
  5. Penguin
  6. Boost

How to call this example

<%= render "govuk_publishing_components/components/list", {
  list_type: "number",
  visible_counters: true,
  items: [
    sanitize("Tony&rsquo;s Chocolonely"),
    sanitize("<a href=\"https://en.wikipedia.org/wiki/Cherry_Ripe_(chocolate_bar)\" rel=\"noopener\" class=\"govuk-link\">Cherry Ripe</a>"),
    "Snickers",
    "Chomp",
    "Penguin",
    "Boost"
  ]
} %>