<template>
    <!-- intentionally empty -->
</template>
<script setup>
if (import.meta.client) {
  useHead({
    script: [
      {
        innerHTML: `
          var _paq = window._paq = window._paq || [];
          _paq.push(["setDocumentTitle", document.domain + "/" + document.title]);
          _paq.push(["setCookieDomain", "*.digimedialoop.de"]);
          _paq.push(["disableCookies"]);
          _paq.push(['trackPageView']);
          _paq.push(['enableLinkTracking']);
          (function() {
            var u = "//analytics.digimedialoop.de/";
            _paq.push(['setTrackerUrl', u + 'matomo.php']);
            _paq.push(['setSiteId', '1']);
            var d = document, g = d.createElement('script'), s = d.getElementsByTagName('script')[0];
            g.async = true; g.src = u + 'matomo.js'; s.parentNode.insertBefore(g, s);
          })();
        `,
        type: 'text/javascript',
        charset: 'utf-8',
        // Optional: ID zum gezielten Sanitizer deaktivieren
        hid: 'matomo-script'
      },
      {
        src: 'https://umami.digimedialoop.de/script.js',
        defer: true,
        'data-website-id': '7f521c0f-28b8-4ca8-82bf-150a34e14da6'
      }
    ],
    __dangerouslyDisableSanitizersByTagID: {
      'matomo-script': ['innerHTML']
    }
  })
}
</script>
