Something went wrong. Try again.
[READ-ONLY] Mirror of https://github.com/fare-asso/fare-website. fare-asso.fr
Something went wrong. Try again.
1234567891011121314151617import { sentryGlobalFunctionMiddleware, sentryGlobalRequestMiddleware} from "@sentry/tanstackstart-react"import { createCsrfMiddleware, createStart } from "@tanstack/react-start"
// Defining a custom start instance disables the default CSRF protection, so// re-add it explicitly.const csrfMiddleware = createCsrfMiddleware({ filter: (ctx) => ctx.handlerType === "serverFn"})
export const startInstance = createStart(() => ({ requestMiddleware: [sentryGlobalRequestMiddleware, csrfMiddleware], functionMiddleware: [sentryGlobalFunctionMiddleware]}))