Closed pauldambra closed 6 days ago
The latest updates on your projects. Learn more about Vercel for Git âī¸
Name | Status | Preview | Updated (UTC) |
---|---|---|---|
posthog-js | â Ready (Inspect) | Visit Preview | Nov 19, 2024 11:36am |
Size Change: +10.4 kB (+0.33%)
Total Size: 3.12 MB
Filename | Size | Change | |
---|---|---|---|
dist/all-external-dependencies.js |
204 kB | -6 B (0%) | |
dist/array.full.es5.js |
254 kB | +1.06 kB (+0.42%) | |
dist/array.full.js |
357 kB | +940 B (+0.26%) | |
dist/array.full.no-external.js |
356 kB | +940 B (+0.27%) | |
dist/array.js |
171 kB | +943 B (+0.55%) | |
dist/array.no-external.js |
170 kB | +941 B (+0.56%) | |
dist/dead-clicks-autocapture.js |
13.6 kB | +78 B (+0.58%) | |
dist/external-scripts-loader.js |
2.27 kB | +74 B (+3.37%) | |
dist/main.js |
172 kB | +1.01 kB (+0.59%) | |
dist/module.full.js |
357 kB | +1 kB (+0.28%) | |
dist/module.full.no-external.js |
356 kB | +1 kB (+0.28%) | |
dist/module.js |
171 kB | +1 kB (+0.59%) | |
dist/module.no-external.js |
170 kB | +1 kB (+0.59%) | |
dist/recorder-v2.js |
113 kB | +71 B (+0.06%) | |
dist/recorder.js |
113 kB | +71 B (+0.06%) | |
dist/surveys-preview.js |
56.7 kB | +71 B (+0.13%) | |
dist/surveys.js |
62.1 kB | +81 B (+0.13%) | |
dist/tracing-headers.js |
1.4 kB | +74 B (+5.57%) | đ |
have updated and tested the examples in the posthog.com docs PR
and tested this locally
i think this is good to go
@robbie-c how about allowing an array of functions...
then we can do
before_send: [
sampleByDistinctId(0.5), // only half of people
sampleByEvent(['$web_vitals], 0.1), // and they capture all events except 10% of web vitals
]
Makes sense, would you multiply the sample thresholds together?
see RFC: https://github.com/PostHog/product-internal/pull/668/ see docs PR: https://github.com/PostHog/posthog.com/pull/9844
The number of config options to redact urls or edit properties is growing It is simpler to have a single hook where you can edit an event before it is captured
This also allows the enterprising customer configure a sampling function
tested locally and event capture still works without a beforeSend set and e.g. the pre-canned event sampling function works as expected