-
Notifications
You must be signed in to change notification settings - Fork 20
Expand file tree
/
Copy pathnetlify.toml
More file actions
35 lines (29 loc) · 855 Bytes
/
netlify.toml
File metadata and controls
35 lines (29 loc) · 855 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
[build]
command = "npm run build"
publish = ".next"
[[plugins]]
package = "@netlify/plugin-nextjs"
# Disable Netlify's post-processing that breaks Next.js
[build.processing]
skip_processing = true
# Next.js static assets are content-hashed — safe to cache forever
[[headers]]
for = "/_next/static/*"
[headers.values]
Cache-Control = "public, max-age=31536000, immutable"
# Page data (includes _meta.json routing) — must revalidate on deploy
[[headers]]
for = "/_next/data/*"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
# HTML pages — never serve stale
[[headers]]
for = "/*.html"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
# Root and page routes
[[headers]]
for = "/*"
[headers.values]
X-Frame-Options = "DENY"
X-Content-Type-Options = "nosniff"