Repository navigation
Adds all.min.js: filtering and the browser sensor in one tag.
Two tags on every page is two things to paste, two things to paste wrong, and two requests. This is both in one file.
<script defer
data-public-key="YOUR_PUBLIC_KEY"
data-blocked-page="https://example.com/blocked"
src="https://cdn.jsdelivr.net/gh/moonito-net/lib@2.0.0/all.min.js"
integrity="sha384-VZ68WATj2o5YUO8bZ1L84gaexLLf6PqpDBBNPLJfgPNN5KUjd+M7APWoGiulEH91"
crossorigin="anonymous"></script>Nothing existing moved
analytics.min.js is untouched, on the tag and on the branch. The new file is at a new path on purpose: jsDelivr caches a branch path for seven days and nothing can clear it early, so publishing there would have pushed this to every existing install whether they asked for it or not.
The filtering half of all.min.js is byte for byte the code published as 1.0.0. It is concatenated onto the sensor rather than merged with it, so each half is a self contained function and neither can break the other.
The sensor half also reads data-public-key
It used to require data-key. Reading the attribute the filtering snippet already used is what lets one tag do both jobs.
Checksums for all.min.js
size 10485 bytes
sha384 VZ68WATj2o5YUO8bZ1L84gaexLLf6PqpDBBNPLJfgPNN5KUjd+M7APWoGiulEH91