add cache header to static assets

This commit is contained in:
MapleLeaf
2022-01-07 02:54:21 -06:00
parent 449b99f76f
commit 44e91d394b

View File

@@ -63,6 +63,7 @@ export class AssetBuilder {
res
.status(200)
.type(extension.endsWith("tsx") ? "text/javascript" : extension)
.header("Cache-Control", "public, max-age=604800, immutable")
.sendFile(file)
return
}