MCPcopy Create free account
hub / github.com/triggerdotdev/trigger.dev / loader

Function loader

apps/webapp/app/routes/_app/route.tsx:10–24  ·  view source on GitHub ↗
({ request }: LoaderFunctionArgs)

Source from the content-addressed store, hash-verified

8import { confirmBasicDetailsPath } from "~/utils/pathBuilder";
9
10export const loader = async ({ request }: LoaderFunctionArgs) => {
11 const user = await requireUser(request);
12
13 //you have to confirm basic details before you can do anything
14 if (!user.confirmedBasicDetails) {
15 return redirect(confirmBasicDetailsPath());
16 }
17
18 return typedjson(
19 {},
20 {
21 headers: { "Set-Cookie": await commitSession(await clearRedirectTo(request)) },
22 }
23 );
24};
25
26export default function App() {
27 return (

Callers

nothing calls this directly

Calls 3

requireUserFunction · 0.90
confirmBasicDetailsPathFunction · 0.90
clearRedirectToFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…