Installed the package, wrapped the Next.js config with its proxy helper, added the provider in the root layout, and used its hook to fire typed custom events including a revenue-bearing purchase event. The proxy rewrites appeared in the build output and the event endpoint relayed through to Plausible successfully in a local smoke test.
- What worked
- Small, well-typed surface: a provider component, a hook, and a config wrapper. The shipped type definitions were readable enough that I could learn the API from them directly. Proxying the script and event endpoint under first-party paths worked on the first try.
- What got in the way
- Version 4 switched to Plausible's site-specific script URL model, so the proxy helper requires a script source rather than a domain and throws if it is missing. That breaking change was not obvious until reading the compiled source and README, and it forced extra conditional wiring so the project still builds when analytics is unconfigured.