Add Pirsch analytics (#795)
### Prerequisites
Put an `x` into the box(es) that apply:
- [ ] This pull request fixes a bug.
- [x] This pull request adds a feature.
- [ ] This pull request introduces breaking change.
### Description
Adds support for [Pirsch](https://pirsch.io) analytics.
One of the best privacy-friendly, open source and lightweight analytics
providers.
### Issues Resolved
N/A
### Checklist
Put an `x` into the box(es) that apply:
#### General
- [x] Describe what changes are being made
- [x] Explain why and how the changes were necessary and implemented
respectively
- [ ] Reference issue with `#<ISSUE_NO>` if applicable
#### Resources
- [ ] If you have changed any SCSS code, run `make release` to
regenerate all CSS files
#### Contributors
- [ ] Add yourself to `CONTRIBUTORS.md` if you aren't on it already
Signed-off-by: Nour Agha <nour@agha.dev>
Co-authored-by: Luiz F. A. de PrĂ¡ <luizdepra@users.noreply.github.com>
3 files modified
2 files added
| | |
| | | * [Goat Counter](https://www.goatcounter.com/) - [documentation](/docs/analytics/goatcounter.md) |
| | | * [Matomo](https://matomo.org/) - [documentation](/docs/analytics/matomo.md) |
| | | * [Micro Analytics](https://microanalytics.io/) - [documentation](/docs/analytics/microanalytics.md) |
| | | * [Pirsch](https://pirsch.io/) - [documentation](/docs/analytics/pirsch.md) |
| | | * [Plausible Analytics](https://plausible.io/) - [documentation](/docs/analytics/plausible.md) |
| | | * [Umami](https://umami.is/) - [documentation](/docs/analytics/umami.md) |
| | | * [Wide Angle Analytics](https://wideangle.co/) - [documentation](/docs/analytics/wideangle.md) |
| New file |
| | |
| | | # Pirsch |
| | | |
| | | ```toml |
| | | [params.pirsch] |
| | | code = "ABCDE" |
| | | ``` |
| | |
| | | # id = "ABCDE" |
| | | # dnt = "false" # respect DNT tracker, "true" by default |
| | | |
| | | # If you want to use Pirsch(https://pirsch.io) for analytics, add this section |
| | | # [params.pirsch] |
| | | # code = "ABCDE" |
| | | |
| | | # If you want to implement a Content-Security-Policy, add this section |
| | | # [params.csp] |
| | | # childsrc = ["'self'"] |
| | |
| | | {{- partial "analytics/umami" . -}} |
| | | {{ end }} |
| | | |
| | | {{ if and .Site.Params.pirsch .Site.Params.pirsch.code }} |
| | | {{- partial "analytics/pirsch" . -}} |
| | | {{ end }} |
| | | |
| | | {{- partial "body/extensions" . -}} |
| | | </body> |
| | | |
| New file |
| | |
| | | <script async defer type="text/javascript" src="https://api.pirsch.io/pirsch.js" |
| | | id="pirschjs" |
| | | data-code="{{ .Site.Params.pirsch.code }}"></script> |