Properties

Details of the properties that you can configure when using the nunjucks version of this component.

Name Type Required Description
showNav boolean Yes Set to "true" to show the navigation links in the header.
showSearch boolean Yes Set to "true" to show the site search input form.
showHeaderActionLinks boolean Yes Set to "true" to show list if items in the top right of page.
homeHref string No The href of the link for the logo and mobile home link in the navigation links. Defaults to "/".
ariaLabel string No Aria label for the logo href. Defaults to "DfE homepage".
logoPath string Yes Set this to the local path for images. In version 13 of the prototype kit, set this is 'public/images'.
selectedNav string No Pass in a value from the view which matches the primaryLinks.label and it will add the class dfe-header__navigation-item--current to the corresponding nav item.
headerActionLinks array No Array of links for use in the header on the top right.
headerActionLinks[].url string No The href of a navigation item in the header. If blank, it will just display the label
headerActionLinks[].label string No The label of the item in the header.
primaryLinks array No Array of navigation links for use in the header.
primaryLinks[].url string No The href of a navigation item in the header.
primaryLinks[].label string No The label of a navigation item in the header.
service object No Object containing the *name* of the service.
attributes object No Any extra HTML attributes (for example data attributes) to add to the header container.
searchAction string No The search action endpoint. Defaults to "/search".
searchInputName string No The name for the search field. Defaults to "searchterm".