Form date input example
With error
When an error message is rendered each input field takes the value of error_id as a value for the aria-describedby attribute. Note that error_id is optional, if it is not passed one will be generated automatically.
How it looks (preview)
How to call this example
<%= render "govuk_publishing_components/components/date_input", {
legend_text: "What is your date of birth?",
hint: "For example, 31 3 1980",
error_id: "error_item_id",
error_message: "Error message goes here"
} %>