simonw / datasette-lite

Datasette running in your browser using WebAssembly and Pyodide
https://lite.datasette.io
Apache License 2.0
329 stars 27 forks source link

Describe use of analytics in README #61

Closed ross-spencer closed 1 year ago

ross-spencer commented 1 year ago

It'd be great to get a statement about how the analytics in this tool are used. I.e. what's collected, and how it's used. Possibly something for the README. Further, perhaps it can be made easier to toggle on and off?

https://github.com/simonw/datasette-lite/blob/e402b4e60dcfbf668980cc1425cbfde1c29d8514/index.html#L172-L173

Connected to: https://github.com/simonw/datasette-lite/issues/22 Partially connected to: https://github.com/pyodide/pyodide/issues/140#issuecomment-1406516885

simonw commented 1 year ago

This is a good call. I'll document the analytics and add a ?analytics=off parameter that can be used to opt out entirely - useful for people who want to link to Datasette Lite but don't want the URL they are opening to be logged anywhere (outside of any GitHub Pages logs which I have no control over or visibility into).

simonw commented 1 year ago

With ?analytics=off:

CleanShot 2023-03-16 at 16 36 09@2x

There's one fetch to Plausible to get the script.manual.js file but there are no further hits actually tracking analytics.

Without that parameter:

image

Note two hits to event on Plausible, because I navigated within the interface after it loaded.

simonw commented 1 year ago

Here's the new section in the README: https://github.com/simonw/datasette-lite/blob/main/README.md#analytics