create-croissant 0.1.21 → 0.1.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "0.1.21",
6
+ "version": "0.1.22",
7
7
  "description": "Scaffold a new project using the Croissant Stack",
8
8
  "repository": {
9
9
  "type": "git",
@@ -18,6 +18,9 @@ export const Route = createFileRoute("/(public)/")({
18
18
  planets,
19
19
  }
20
20
  },
21
+ headers: () => ({
22
+ "Cache-Control": "public, max-age=10, s-maxage=10, stale-while-revalidate=60",
23
+ }),
21
24
  component: App,
22
25
  })
23
26
 
@@ -2,6 +2,9 @@ import { createFileRoute } from "@tanstack/react-router"
2
2
  import { LoginForm } from "@/components/login-form"
3
3
 
4
4
  export const Route = createFileRoute("/(public)/login")({
5
+ headers: () => ({
6
+ "Cache-Control": "public, max-age=3600, s-maxage=3600, stale-while-revalidate=86400",
7
+ }),
5
8
  component: Login,
6
9
  })
7
10
 
@@ -2,6 +2,9 @@ import { createFileRoute } from "@tanstack/react-router"
2
2
  import { SignupForm } from "@/components/signup-form"
3
3
 
4
4
  export const Route = createFileRoute("/(public)/signup")({
5
+ headers: () => ({
6
+ "Cache-Control": "public, max-age=3600, s-maxage=3600, stale-while-revalidate=86400",
7
+ }),
5
8
  component: Signup,
6
9
  })
7
10
 
@@ -10,7 +10,8 @@ const config = defineConfig({
10
10
  tailwindcss(),
11
11
  tanstackStart({
12
12
  prerender: {
13
- filter: ({ path }) => path === "/examples/isr",
13
+ // In this version of TanStack Start, we use 'filter' to specify ISR routes
14
+ filter: ({ path }) => ["/", "/login", "/signup", "/examples/isr"].includes(path),
14
15
  },
15
16
  }),
16
17
  viteReact(),