Add basic login screen with form-based authentication
Adds /login route with HTML template that handles GET (show form) and POST (authenticate). On successful login, sets session cookie and redirects to /. Also adds framework support for redirects and cookies in route handlers. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -25,7 +25,9 @@ const okText = (result: string): Result => {
|
||||
|
||||
const routes: Route[] = [
|
||||
...authRoutes,
|
||||
basicRoutes.home,
|
||||
basicRoutes.hello,
|
||||
basicRoutes.login,
|
||||
{
|
||||
path: "/slow",
|
||||
methods: ["GET"],
|
||||
|
||||
Reference in New Issue
Block a user