Skip to content

Commit

Permalink
Enhance : Unification in services page
Browse files Browse the repository at this point in the history
  • Loading branch information
cp-jagruti-a committed Jan 5, 2024
1 parent 6d13e3c commit f3d5ca7
Showing 1 changed file with 7 additions and 12 deletions.
19 changes: 7 additions & 12 deletions nuxt-frontend/nuxt.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,6 @@ export default defineNuxtConfig({
htmlAttrs: {
lang: "en",
},
routeRules: {
"/assets/images/**": {
headers: {
"cache-control": `public,max-age=${yearInSeconds},s-maxage=${yearInSeconds}`,
},
},
"/_nuxt/**": {
headers: {
"cache-control": `public,max-age=${yearInSeconds},s-maxage=${yearInSeconds}`,
},
},
},
},
},
devtools: { enabled: true },
Expand Down Expand Up @@ -49,4 +37,11 @@ export default defineNuxtConfig({
failOnError: false,
},
},
render: {
// Setting up cache for 'static' directory - a year in milliseconds
// https://web.dev/uses-long-cache-ttl
static: {
maxAge: 60 * 60 * 24 * 365 * 1000,
},
},
});

0 comments on commit f3d5ca7

Please sign in to comment.