zonemaster-gui
zonemaster-gui copied to clipboard
Support for analytics in configuration
It should be possible in the configuration (#219) to add a custom block of HTML near the foot of every page. This would give us an easy way to use analytics tools that don't disappear when you reinstall or upgrade Zonemaster GUI. That way we could add something like Goat Counter (a more privacy minded alternative to Google Analytics) to zonemaster.net so we can get a better picture of how it's being used.
Since the index.html page is the only html page loaded (Single Page Application), you only need to put the code once.
Hello @pamasse! Nice to see you around :)
But index.html is overwritten when you reinstall Zonemaster GUI or upgrade it to a newer version, and then you have to update it again, right?
Yes, a technical solution will be to supercharge the starting script with a "user configuration loading script". This script will inject the javascript and HTML code associated with the analytical solution.
Another solution could be to implement a generic solution such as https://github.com/angulartics/angulartics2, and pre-configure the library with specific metrics such as, how many people launch a test, how many read the FAQ pages, how many visitors change the language, etc. It more time expensive.