Skip to content

Commit a15f7dd

Browse files
committed
chore: default callbackUrl to /profile + drop unused demo routes + bump typescript-eslint to ^8.60
1 parent 76bb154 commit a15f7dd

4 files changed

Lines changed: 3 additions & 15 deletions

File tree

app/routes/auth/login.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ interface AuthProvider {
2222
function LoginPage() {
2323
const search = Route.useSearch() as Record<string, string | undefined>;
2424
const error = search.error;
25-
const callbackUrl = search.callbackUrl ?? '/';
25+
const callbackUrl = search.callbackUrl ?? '/profile';
2626
const { message } = getMessage(error, 'signin-error');
2727

2828
const [csrfToken, setCsrfToken] = useState('');

app/server.tsx

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -181,18 +181,6 @@ async function handleRequest(request: Request): Promise<Response> {
181181
}
182182
}
183183

184-
// Public API endpoint — no authentication required.
185-
if (pathname === '/api/unprotected') {
186-
return Response.json({ ok: true });
187-
}
188-
189-
// Session-protected API endpoints — return 403 when unauthenticated.
190-
if (pathname === '/api/secured' || pathname === '/api/protected/middleware') {
191-
const session = await getSession(request);
192-
if (!session) return Response.json({ error: 'Forbidden' }, { status: 403 });
193-
return Response.json({ ok: true });
194-
}
195-
196184
// Everything else → TanStack Start SSR router
197185
return tanstackHandler(request);
198186
}

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@
4646
"prettier-plugin-tailwindcss": "^0.8.0",
4747
"tailwindcss": "^4.3.0",
4848
"typescript": "~5.9.2",
49-
"typescript-eslint": "^8.20.0",
49+
"typescript-eslint": "^8.60.0",
5050
"vite": "^7.3.2"
5151
}
5252
}

0 commit comments

Comments
 (0)