14 blog post schedule
This commit is contained in:
@@ -4,6 +4,17 @@ import type { NextRequest } from 'next/server';
|
||||
export function middleware(req: NextRequest) {
|
||||
const path = req.nextUrl.pathname;
|
||||
|
||||
// 301 Redirects for /guide -> /learn to avoid duplicate content and consolidate authority
|
||||
if (path === '/guide/tracking-analytics') {
|
||||
return NextResponse.redirect(new URL('/learn/tracking', req.url), 301);
|
||||
}
|
||||
if (path === '/guide/bulk-qr-code-generation') {
|
||||
return NextResponse.redirect(new URL('/learn/developer', req.url), 301);
|
||||
}
|
||||
if (path === '/guide/qr-code-best-practices') {
|
||||
return NextResponse.redirect(new URL('/learn/basics', req.url), 301);
|
||||
}
|
||||
|
||||
// Public routes that don't require authentication
|
||||
const publicPaths = [
|
||||
'/',
|
||||
@@ -16,7 +27,7 @@ export function middleware(req: NextRequest) {
|
||||
'/newsletter',
|
||||
'/tools',
|
||||
'/features',
|
||||
'/guide',
|
||||
// '/guide', // Redirected to /learn/*
|
||||
'/qr-code-erstellen',
|
||||
'/dynamic-qr-code-generator',
|
||||
'/bulk-qr-code-generator',
|
||||
@@ -31,6 +42,8 @@ export function middleware(req: NextRequest) {
|
||||
'/display',
|
||||
'/contact',
|
||||
'/about',
|
||||
'/learn',
|
||||
'/authors',
|
||||
];
|
||||
|
||||
// Check if path is public
|
||||
|
||||
Reference in New Issue
Block a user