JSPM

@jop-software/astro-matomo

1.1.1
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 64
  • Score
    100M100P100Q89799F
  • License GPL-3.0-or-later

Matomo integration for Astro

Package Exports

  • @jop-software/astro-matomo
  • @jop-software/astro-matomo/matomo.js
  • @jop-software/astro-matomo/package.json

Readme

Matomo + Astro Integration

GDRP friendly tracking in your astro app / site 🚀

Installation

Installation using the Astro CLI

Using the Astro CLI is the recommended way to setup integrations in Astro.

# npm
npx astro add @jop-software/astro-matomo

# pnpm
pnpm dlx astro add @jop-software/astro-matomo

Manual Installation

When the automatic setup from Astro is not an option for you, feel free to install the package manually.

# npm
npm install @jop-software/astro-matomo

# pnpm
pnpm add @jop-software/astro-matomo

Usage

// astro.config.mjs

import matomo from '@jop-software/astro-matomo';

export default defineConfig({
  // We only track site views when this matches the host the user is on.
  // If the configuration is empty, every page view gets tracked.
  site: "https://example.com",
  integrations: [
    matomo({
      baseUrl: "https://analytics.example.com/",
      siteId: 1
    }),
  ]
});