[READ-ONLY] a fast, modern browser for the npm registry
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: adjust badge api caching strategy (#1246)

authored by

btea and committed by
GitHub
6b337755 e19c3948

+7
+7
nuxt.config.ts
··· 88 88 routeRules: { 89 89 // API routes 90 90 '/api/**': { isr: 60 }, 91 + '/api/registry/badge/**': { 92 + isr: { 93 + expiration: 60 * 60 /* one hour */, 94 + passQuery: true, 95 + allowQuery: ['color', 'labelColor', 'label', 'name'], 96 + }, 97 + }, 91 98 '/api/registry/docs/**': { isr: true, cache: { maxAge: 365 * 24 * 60 * 60 } }, 92 99 '/api/registry/file/**': { isr: true, cache: { maxAge: 365 * 24 * 60 * 60 } }, 93 100 '/api/registry/provenance/**': { isr: true, cache: { maxAge: 365 * 24 * 60 * 60 } },