Astro developer in Dublin

Astro site for an Irish business: where a static site still stores or reads data on a visitor's device, what the Data Protection Commission cookie guidance of April 2020 requires, and how I wire consent so scripts wait.

Astro developer

Migrate from WordPress to Astro in Dublin

Many businesses in Dublin run WordPress but face performance ceilings, security overhead, and rising hosting costs. Astro solves these with static HTML output, zero JavaScript by default, and edge deployment. I migrate existing WordPress sites to Astro with full SEO preservation, URL mapping, and 301 redirects.

  • PageSpeed 95-100

    Static HTML with zero JavaScript. Faster than any WordPress solution.

  • SEO-safe migration

    URL mapping, 301 redirects, Google rankings preserved.

  • Cloudflare Pages hosting

    Global CDN, free SSL, instant deployments. Hosting costs near zero.

Astro has a reputation for sending almost no JavaScript, and for a plain brochure site that is also a privacy advantage. The legal question starts later: the day someone adds an analytics tag, a map or a chat widget. Regulation 5 of S.I. 336/2011 governs that moment, and the Data Protection Commission, the national authority for the Irish ePrivacy rules, has set out how it reads the regulation in its guidance on cookies and other tracking technologies. I use the full April 2020 guidance note and the text of the regulations as my references.

Campanile of Trinity College Dublin

Photo: Acediscovery, CC BY-SA 4.0, Wikimedia Commons.

#Does a static Astro site set cookies?

By default it sets nothing of its own. The Astro islands documentation says Astro renders every UI component to HTML and CSS and strips client-side JavaScript automatically, unless you opt a component in with a client directive. A page with no scripts has no client code that can write to a device.

That is where the comfort ends, because the regulation does not stop at cookies. The DPC lists local storage objects, software development kits, pixel trackers, like buttons and social sharing tools, and device fingerprinting as covered technologies. It says it makes no difference whether the information stored or read is personal data. So the review has to cover anything that writes or reads on the device, whatever the mechanism.

#Where an Astro site starts storing data

A short list of additions covers most Astro sites. The right column gives the position under the guidance.

What the site addsPosition under the guidance
Analytics tagConsent required; the guidance answers “Do analytics cookies require consent?” with “Yes”
Chat widgetCookies must not be deployed until the person explicitly requests chat
Like button, share tool, pixelConsent, and you may be a joint controller with the third party
Embedded map or videoNot named; if the embed stores or reads anything on the device, consent comes first
Payment providerNeeds a controller-processor contract under GDPR Article 28(3); may also be a controller
Language or country preferenceStrictly necessary, no consent
Basket session cookieStrictly necessary if it expires with the session or shortly after

The guidance applies the same two-part test to anything not on this list: the item either serves the sole purpose of transmitting a communication, or it is strictly necessary for a service the visitor explicitly requested. Cookies related to advertising are not strictly necessary. How you label a cookie, “functionality” or “performance” for example, does not change the test.

#Where do scripts load in Astro?

The Astro client-side scripts guide explains the distinction that matters here. A plain <script> tag is processed: Astro bundles it, resolves imports, supports TypeScript, and includes it once per page even if several components use it. A script with any attribute other than src is left unprocessed, and is:inline opts out of processing deliberately. External scripts from another server need is:inline as well, which skips Astro’s bundling and optimisation.

That has a direct consequence for consent. A third-party analytics tag pasted into a layout as <script is:inline src="https://..."> runs on every page load, before any banner. The consent decision has to come first, so the third-party script must not appear in the HTML at all. I create it from a processed script after the visitor agrees.

This is the pattern I use. It sits in one component imported by the base layout, so the logic exists once:

---
// src/components/Consent.astro
---
<script>
  const NAME = 'consent'
  const stored = () =>
    document.cookie.split('; ').find((c) => c.startsWith(NAME + '='))?.split('=')[1]

  function loadAnalytics() {
    const s = document.createElement('script')
    s.src = 'https://analytics.example.com/script.js'
    s.defer = true
    document.head.append(s)
  }

  function save(choice: 'granted' | 'denied') {
    const until = new Date()
    until.setMonth(until.getMonth() + 6)
    document.cookie = `${NAME}=${choice}; expires=${until.toUTCString()}; path=/; SameSite=Lax; Secure`
    if (choice === 'granted') loadAnalytics()
  }

  if (stored() === 'granted') loadAnalytics()
  document.querySelector('[data-consent-accept]')?.addEventListener('click', () => save('granted'))
  document.querySelector('[data-consent-reject]')?.addEventListener('click', () => save('denied'))
</script>

Three details follow the guidance. The record expires after six months, which the DPC calls the appropriate outer limit and says needs objective, case-by-case justification if longer. Rejecting is one click, next to accepting. And nothing loads until a positive action, because the guidance says silence or inaction cannot be consent.

#What must the banner do?

The guidance is specific about the interface, and several points are easy to miss in a design review:

  • Accept and reject get equal prominence, or the banner offers a manage option that leads to a layer where the visitor can choose by type and purpose.
  • A banner with only “ok, got it” or “I understand” is not compliant. At minimum it must let the visitor reject non-necessary cookies or ask for more information.
  • The banner must not cover the text of the privacy or cookie policy. The visitor has to be able to read both without any non-exempt cookie being set, and the policy text must not be disrupted by a chatbot or other page feature.
  • The first layer says which purposes you ask about. The second layer names the types, the purposes and the third parties that will process the data.
  • Consent cannot be bundled across purposes, or with acceptance of terms for another service.
  • A banner that disappears when the visitor scrolls, with no engagement, is not compliant.
  • Colour schemes for banners and sliders that blend into the background are hard for people with vision impairments. The DPC suggests testing with users who have vision or reading impairments.

The banner is ordinary HTML in an Astro component, so I test contrast and keyboard order on it like any other part of the page.

Regulation 5(4) says consent may be given by appropriate browser settings or another technological application where that is technically possible and effective. The DPC reads that narrowly. Visitors cannot be deemed to have consented because their browser enables collection by default, and a general line in a privacy policy telling people how to switch off third-party cookies does not meet the clear and comprehensive information test. Where browser settings might count, the guidance expects them to be very limited and assessed case by case.

For a build, the rule is simple: an absent signal is not a yes. The script waits for an affirmative action in the banner, whatever the browser sends.

#Joint controllers, processors and the paperwork behind a banner

Two items in the guidance reach past the banner. First, where you deploy like buttons, plugins, widgets or pixel trackers, you should know what data goes to the third party, because you may be a controller for the data you collect and disclose to it. The DPC cites the Fashion ID judgment of July 2019. Second, for a payment provider you need a controller-processor contract that meets Article 28(3) of the GDPR, and the provider may also have a controller role for data passed through cookies.

If a third-party consent management platform keeps the record of the visitor’s choice, the guidance requires you to keep a record of that consent as part of your record of processing activities under Article 30. It also says the tool must do what it claims, with no pre-checked boxes, and that consent must be as easy to withdraw as to give.

#When is a data protection impact assessment needed?

The guidance points to the DPC’s list of processing operations that require an impact assessment. It names systematic monitoring or tracking of location or behaviour, large-scale profiling, and combining datasets from different sources or controllers where the linking contributes to profiling. An Astro marketing site rarely reaches that point. A site that stitches analytics, CRM and advertising audiences together can.

Two related rules apply earlier. Tracking a user’s location, or deriving it from cookies, needs consent. And for special category data derived from cookies, such as health or political opinions, the guidance says the only likely legal basis is explicit consent, which generic wording in a banner or policy is unlikely to satisfy.

#Fonts, maps and embeds

Fonts are a request to a third party that many teams forget. The Astro fonts guide describes a Fonts API that downloads and caches fonts so they are served from your site, with built-in providers including Google, Bunny, Fontsource and local files. The guide says this can avoid sending user data to third-party sites. I use it, then check the network tab to confirm no request leaves the domain.

Maps and video are different. An embedded iframe loads third-party code on page load. My default is a placeholder with a plain link and an explicit button that loads the embed after the visitor agrees, which also matches the chat widget rule above.

#What if the site gets this wrong?

The DPC says it allowed six months from publication of the April 2020 guidance for controllers to bring websites and mobile apps into compliance, after which enforcement action would commence. It also says controllers must not change cookie practice on the strength of proposed legislation that has not been enacted. For related enforcement powers under the regulations, my WordPress developer page for Dublin walks through regulation 17 and 27.

#How a project with me runs

One developer does the work, remotely and in writing, so the steps for a Dublin Astro project are short:

  1. You send the URL, the goal, the deadline and the current stack. The first email reply, within 24 hours on working days, says what I would look at first.
  2. I load the site in a clean browser, reject everything and list every cookie, storage key and third-party request. Then I accept and compare the two lists.
  3. A written note sets the scope, the assumptions and my questions, and I start once you approve it.
  4. The build runs on a private preview link. I design the layout or implement yours, and I test no choice, reject and accept, on desktop and mobile.
  5. Once you accept in writing, the site goes live, and a maintenance option keeps Astro and its dependencies current.

What I need from you: repository or hosting access, the tag manager and analytics accounts, and the name of whoever decides on advertising tags.

#Checklist you can use without me

  • List every cookie, local storage key and third-party request in a clean browser before touching the banner.
  • Mark each as communication, strictly necessary or consent, and write down why.
  • Confirm that no analytics, chat, social or advertising script is in the HTML before a positive action.
  • Put reject next to accept, or a manage option that leads to purposes and third parties.
  • Keep the privacy and cookie policy readable without any non-exempt cookie being set.
  • Store the consent state for no longer than six months, then ask again.
  • If a third-party tool holds the record, add it to your record of processing activities.
  • Check controller-processor contracts for payment and analytics providers.

For the wider service see the Astro developer page.

#Send me the site and the tag list

If you run an Astro site in Dublin, or plan one, send me the URL, what the site must achieve, your deadline and the stack it runs on, through the contact page. The written estimate is free. If you already have a tag list, attach it and I will mark it against the guidance in the first reply.

Need this service: Astro developer in Dublin?

Describe your project by e-mail. I reply within 24 hours.

Describe your project

Explore other WordPress services and knowledge base