Code Explainers

Code explainers tagged #edge-runtime

javascript
import { NextResponse } from 'next/server';
import { jwtVerify } from 'jose';
 
const PROTECTED_PREFIXES = ['/dashboard', '/settings', '/billing'];

Gating routes with Next.js middleware and JWTs

authentication middleware jwt
Intermediate 8 steps