UNPKG

@inertiapixel/nextjs-auth

Version:

Authentication system for Next.js. Supports credentials and social login, JWT token management, and lifecycle hooks — designed to integrate with nodejs-auth for full-stack MERN apps.

6 lines (5 loc) 191 B
export function getApiBaseUrl(req) { const urlParam = req.nextUrl.searchParams.get('apiBaseUrl'); // Prefer query param over env (if you want fallback) return urlParam || null; }