g1t/apps/web/app/routes/not-found.tsx
Pick any line to see why it is the way it is: the commit, the pull request and issue it came from, and what the agent was thinking.
| Webhooks: every event, to your own addresses, signed and retried | 1 | import { data } from "react-router"; |
| 2 | ||
| Agents and memory, checks and conflicts, profiles, slug renames, custom domains | 3 | import type { Route } from "./+types/not-found"; |
| 4 | import { redirectIfRenamed } from "../lib/renamed.server"; | |
| 5 | ||
| Webhooks: every event, to your own addresses, signed and retried | 6 | /** |
| 7 | * Any address no other route matches. Throwing the 404 from a route, rather | |
| 8 | * than leaving the router to, means the root loader still runs, so someone | |
| 9 | * signed in sees the page in their own sidebar and not the public frame. | |
| Agents and memory, checks and conflicts, profiles, slug renames, custom domains | 10 | * |
| 11 | * An address under a renamed workspace's old name is sent to the new one | |
| 12 | * first, so deep links keep working the same as its pages do. | |
| Webhooks: every event, to your own addresses, signed and retried | 13 | */ |
| Agents and memory, checks and conflicts, profiles, slug renames, custom domains | 14 | export async function loader({ request }: Route.LoaderArgs) { |
| 15 | const first = new URL(request.url).pathname.split("/")[1]; | |
| 16 | if (first) await redirectIfRenamed(request, first); | |
| Webhooks: every event, to your own addresses, signed and retried | 17 | throw data(null, { status: 404 }); |
| 18 | } | |
| 19 | ||
| 20 | export default function NotFound() { | |
| 21 | return null; | |
| 22 | } |