Files
webstudio/apps/builder/app/routes/builder.tsx
T
Ivan Starkov 7e1ec54079 build: Fix timeout error (#3222)
The only way I found to make it work is to deploy all functions again
Was:
<img width="1245" alt="image"
src="https://github.com/webstudio-is/webstudio/assets/5077042/2ce88b6a-3bdd-4c58-b690-fa2f5b35cb18">

Now:
<img width="1228" alt="image"
src="https://github.com/webstudio-is/webstudio/assets/5077042/a90ee191-fb4b-4666-859f-502e06929099">


Any ideas why rest/ai so much smaller than all other routes?
2024-04-23 11:48:39 +03:00

27 lines
790 B
TypeScript

import type { ServerRuntimeMetaFunction as MetaFunction } from "@remix-run/server-runtime";
import { Root } from "~/shared/remix/root";
import type { ShouldRevalidateFunction } from "@remix-run/react";
export const meta: MetaFunction = () => {
return [{ title: "Webstudio" }];
};
/**
* We do not want trpc and other mutations that use the Remix useFetcher hook
* to cause a reload of all builder data.
*/
export const shouldRevalidate: ShouldRevalidateFunction = ({
currentUrl,
nextUrl,
defaultShouldRevalidate,
}) => {
return currentUrl.href === nextUrl.href ? false : defaultShouldRevalidate;
};
export default Root;
// Reduces Vercel function size from 29MB to 9MB for unknown reasons; effective when used in limited files.
export const config = {
maxDuration: 30,
};