Skip to content

Commit b525c8c

Browse files
nayijmokhld
andauthored
512731_Add cacheing for static assets (#740)
* 512731_Add cacheing for static assets * fix: disable static asset caching for local development Use isProduction config flag to only enable immutable caching on deployed environments (dev, test, perf-test, prod). --------- Co-authored-by: Mohammed Khalid <emailmokhld@gmail.com>
1 parent 9c43c1e commit b525c8c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/server/routes/public.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export default [
2323
{
2424
from: '/assets/{path*}',
2525
to: join(config.get('publicDir'), 'assets'),
26-
immutable: false
26+
immutable: config.get('isProduction')
2727
}
2828
].map((options) => {
2929
return {

0 commit comments

Comments
 (0)