Skip to content

Commit ea9a401

Browse files
committed
fix: change unscoped packages too
1 parent b127c62 commit ea9a401

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

modules/isr-fallback.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ export default defineNuxtModule({
1616
nitro.hooks.hook('compiled', () => {
1717
const spaTemplate = readFileSync(nitro.options.output.publicDir + '/200.html', 'utf-8')
1818
for (const path of [
19+
'package',
20+
'package/[name]',
21+
'package/[name]/v',
22+
'package/[name]/v/[version]',
1923
'package/[org]',
2024
'package/[org]/[name]',
2125
'package/[org]/[name]/v',

nuxt.config.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,8 @@ export default defineNuxtConfig({
108108
},
109109
},
110110
// pages
111+
'/package/:name': { isr: getISRConfig(60, true) },
112+
'/package/:name/v/:version': { isr: getISRConfig(60, true) },
111113
'/package/:org/:name': { isr: getISRConfig(60, true) },
112114
'/package/:org/:name/v/:version': { isr: getISRConfig(60, true) },
113115
// infinite cache (versioned - doesn't change)

0 commit comments

Comments
 (0)