fix(analytics): add proxy route and correct script URL for OpenPanel

- Add /api/op/[...path] proxy route to forward events to self-hosted OpenPanel
- Add scriptUrl=/api/op/op1.js to OpenPanelComponent
- Proxy prevents ad blockers from blocking tracking requests
This commit is contained in:
Unchained
2026-03-25 19:07:52 +02:00
parent 17367024c2
commit cdd3f9c77e
2 changed files with 12 additions and 5 deletions

View File

@@ -0,0 +1,5 @@
import { createRouteHandler } from "@openpanel/nextjs/server";
export const { GET, POST } = createRouteHandler({
apiUrl: "https://op.nodecrew.me/api",
});