Frontend snippet and Kirby panel for Plausible analytics.
Plausible is a lightweight and open-source website analytics tool. No cookies and fully compliant with GDPR, CCPA and PECR. Made and hosted in the EU.
Download and copy this repository to /site/plugins/kirby3-plausible
.
rowdyrabouw.plausible.domain
in config.php for data-domain
in the snippetrowdyrabouw.plausible.sharedLink
in config.php for the panelYou can also set rowdyrabouw.plausible.theme
to overwrite the default (light) theme in the Kirby panel. This can be either light
or dark
.
Add settings to your config/config.php
<?php
return [
'rowdyrabouw.plausible' => [
'domain' => 'example.com', // used in snippet
'theme' => 'light', // light or dark; used in panel
'sharedLink' => 'https://plausible.io/share/example.com?auth=vugsdGWpgFRI4S9nCWmRY' // used in panel
]
];
Place the frontend snippet inside the head tag. Analytics logging is automatically disabled when Kirby is in debug mode.
<?php snippet('rowdyrabouw/plausible'); ?>