You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Teach scripts/jetti-install.mjs to detect Next.js projects and patch the right entry file, so install jetti from https://jetti.co/install.md Just Works on Next.js apps.
Today the install CLI auto-detects plain HTML and Vite/React only. Next.js is the highest-traffic framework in agent-driven workflows, so this is the most-requested adapter.
Scope
App router — patch app/layout.tsx (or app/layout.jsx) by injecting the <Script src='…/snippet.js' data-jetti-session='…' /> tag inside the <head>. Use next/script with strategy='beforeInteractive' so the snippet runs before hydration.
Pages router — patch pages/_document.tsx (or pages/_document.jsx) by injecting the same <Script> inside <Head>.
Detect which router is in use by the presence of app/ vs pages/ (and don't get tripped up by App Router projects that still have a legacy pages/api/ directory).
Update the framework matrix in README.md — flip Next.js rows from 🔜 to ✅.
Out of scope
Server-side reviewer-link rendering. The snippet is client-side only.
Edge runtime detection. The snippet runs in the browser regardless.
Turbopack-specific tweaks. Standard Next.js handles this.
Acceptance
Running install jetti in a fresh npx create-next-app@latest project (both --app and --no-app) patches the correct entry file and the reviewer flow works end-to-end.
A short test fixture lives in scripts/__tests__/ covering both router shapes.
Activity