This monorepo hosts multiple Nexty-powered directory apps plus shared packages (UI kit, analytics helpers, etc.) and internal docs. Each app is a full-stack Next.js 15 project using the App Router, Cloudflare D1 + R2, Better Auth, Stripe, Unsend, and our custom directory widgets.
apps/browserextensions-io-directoryapps/serp-co-directoryapps/docs– marketing + setup docs (Next.js)- Packages under
packages/*provide shared UI, analytics snippets, lint config, and TS config.
Run bun run dev:<app> (for example bun run dev:browserextensions-io-directory) to boot an individual directory, or bun run dev to start everything via Turborepo.
- Ads & Sponsorships –
/dashboard/(admin)/adsmanages banner inventory mapped to placements likehomepage_top,sidebar, and newsletter slots. Frontend consumers (<AdSlot />, sponsor spotlight,/sponsor) automatically pull active placements. - Featured spots & job board – Products flagged with
isFeaturedshow in the homepage hero and sponsor block. The job board supports featured listings, newsletter boosts, and sponsor email handoff via the admin UI. - Dub partner program – Replaced the legacy Tolt snippet with
@dub/analytics. Referral cookies are captured globally, forwarded through Stripe checkout/webhooks, and surfaced in the analytics dashboard + sponsor CTA blocks. Environment variables live under the “Dub Partners” section in.env.example. - Email via Unsend –
actions/unsendcentralizes transactional email. ConfigureUNSEND_SENDER_EMAILto a verified domain inside Unsend, and all newsletters/auth messages inherit the setting. - PostHog & Umami analytics – PostHog captures page views while Umami powers the new admin analytics dashboard (traffic chart, top pages/referrers/countries, revenue snapshot, and partner conversions). All charts reuse the shared
components/ui/chartprimitives. - Cloudflare native stack – Cloudflare D1 + R2 for persistence and assets, Turnstile for bot protection, and Wrangler scripts for provisioning.
All env onboarding (Infisical pulls, Cloudflare vars/secrets, key reference) lives in the docs app:
- Doc page:
apps/docs/content/en/03-Start Project/02-Environment Variables.mdx(route:/docs/start-project/environment)
bun install
# Start a specific directory
bun run dev:browserextensions-io-directory
# Or run everything
bun run devDon’t share one node_modules between Windows + WSL (or across OSes). Native packages (Next SWC, esbuild, workerd) are platform-specific.
- If you’re on WSL, clone into the WSL filesystem (e.g.
~/code/...), not/mnt/c/.... - If you hit “installed on another platform”, run
bun run deps:cleanand reinstall on your current OS.
Stripe, PostHog, and Dub webhooks need your local tunnel (Cloudflare Tunnel, ngrok, etc.) if you test callbacks. The repo intentionally avoids committing .env.local – set secrets per app.
Visit /dashboard/(admin)/analytics to view:
- Visitors/pageviews/bounce rate/avg session (30-day window)
- Area chart with daily visitors (powered by Umami)
- Tables for top pages, referrers, countries, and browsers
- Revenue snapshot (one-time + subscriptions) and # of orders
- Dub partner conversions (grouped by
dub_id, using Stripe order data)
If Umami credentials are missing the dashboard gracefully degrades and surfaces a configuration hint.
- Drop your Dub publishable key + server key into each
.env.local. - Optional: specify refer/site/outbound domains so the script propagates
dub_idacross multi-domain flows. - Stripe checkout automatically includes
dub_idmetadata; webhook handlers call Dub’s/track/saleAPI with the server key. - Marketing CTAs use
NEXT_PUBLIC_DUB_LANDING_URL,NEXT_PUBLIC_DUB_APPLY_URL, andNEXT_PUBLIC_DUB_PORTAL_URLto expose landing/application/portal links on/sponsorand Sponsor Spotlight components.
- Linting:
bun run lint - Formatting:
bun run format - Type check:
bun run check-types - Package-specific commands: use Turborepo filters (example:
bunx turbo run lint --filter=browserextensions-io-directory)
Check docs/ for setup guides or open an issue. The monorepo is structured so directories stay in sync—most template changes should be applied consistently across apps.
Cloudflare Workers docs (OpenNext): https://opennext.js.org/cloudflare