Skip to content

Commit

Permalink
Hide cookie banner from Google search
Browse files Browse the repository at this point in the history
Implemented on the GOVUK Frontend cookie banner
component in:

alphagov/govuk-frontend#2192

This tells Google to ignore the cookie banner when
it indexes the content of our pages.
  • Loading branch information
tombye committed Nov 24, 2022
1 parent dfcea51 commit 1aa2f6d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/templates/components/cookie-banner.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% macro cookie_banner(id='global-cookie-message') %}

<div id="{{ id }}" class="notify-cookie-banner" data-notify-module="cookie-banner" role="region" aria-label="cookie banner">
<div id="{{ id }}" class="notify-cookie-banner" data-nosnippet data-notify-module="cookie-banner" role="region" aria-label="cookie banner">
<div class="notify-cookie-banner__wrapper govuk-width-container">
<h2 class="notify-cookie-banner__heading govuk-heading-m" id="notify-cookie-banner__heading">Can we store analytics cookies on your device?</h2>
<p class="govuk-body">Analytics cookies help us understand how our website is being used.</p>
Expand Down

0 comments on commit 1aa2f6d

Please sign in to comment.