How to Add PostHog Analytics to Astro

Add PostHog analytics to Astro without dragging down page speed: start with the basic script, then move it off the main thread with Partytown.