A simple Django package to render Plausible Analytics html tag
Reason this release was yanked:
Error in distributable, use >=0.0.3
Project description
Django Simple Plausible
A dead simple package to add Plausible Analytics html tag to your HTML. Tested with Python 2.7 and 3.8. Tested with Django 1.11 and 3.2.
Usage
-
Install package:
pip install django_simple_plausible
-
Add
django_simple_plausible
to yourINSTALLED_APPS
in settings.py -
ADD
PLAUSIBLE_SITES
andPLAUSIBLE_SCRIPT_URL
keys and values to your settings.py. Without these settings, default values for Plausible will be used.
...
PLAUSIBLE_SITES = "example.com"
PLAUSIBLE_SCRIPT_URL = "https://example.com/js/plausible.js"
...
- add the following template tags to your site html:
{% load plausible %}
{% plausible %}
Configuring details
- PLAUSIBLE_SITES can be a comma separated list without spaces, if you want to use that feature of Plausible
PLAUSIBLE_SITES = "example.com,yoursite.com"
- Systemwide settings can be overridden giving the template tag some optional parameters:
{% plausible plausible_sites="mysite.com" script_url="https://mysite.com/plausible.js" %}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for django_simple_plausible-0.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | c73d175849a81d3f2accfdecf0f04e95a3369c0a6383836252b1917f0b688082 |
|
MD5 | f3d8b1307bf618e66407e271c32a223e |
|
BLAKE2b-256 | 7bdbd89dc8c6f392a566964166361ad2058042213544a5a8ae337de6cd79934d |
Close
Hashes for django_simple_plausible-0.0.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | dc6624eb804e397be983d607fa776c4b412536701acc36a3be34a147a7a9bc07 |
|
MD5 | c5cf444acd0ccc84cc17d77a742b0301 |
|
BLAKE2b-256 | 8dabf776e5eb564632026ba3e2baba0cfd3557fde24360d5e714987484b532ed |