-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnetlify.toml
More file actions
45 lines (36 loc) · 962 Bytes
/
Copy pathnetlify.toml
File metadata and controls
45 lines (36 loc) · 962 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
36
37
38
39
40
41
42
43
44
[build]
command = "npm run build:prod"
publish = "_site"
[build.environment]
NODE_VERSION = "20"
# Clean URLs — Eleventy already outputs index.html per dir, but add safety redirects
[[redirects]]
from = "/*"
to = "/:splat/index.html"
status = 200
conditions = { Path = ["!*.*"] }
# Cache-Control headers
[[headers]]
for = "/assets/css/*"
[headers.values]
Cache-Control = "public, max-age=31536000, immutable"
[[headers]]
for = "/assets/js/*"
[headers.values]
Cache-Control = "public, max-age=31536000, immutable"
[[headers]]
for = "/assets/icons/*"
[headers.values]
Cache-Control = "public, max-age=86400"
[[headers]]
for = "/manifest.json"
[headers.values]
Cache-Control = "public, max-age=86400"
[[headers]]
for = "/sw.js"
[headers.values]
Cache-Control = "public, max-age=0, must-revalidate"
[[headers]]
for = "/*.html"
[headers.values]
Cache-Control = "public, max-age=3600"