Skip to content

Commit

Permalink
fix(nuxt): allow island renders without / route (#20894)
Browse files Browse the repository at this point in the history
  • Loading branch information
danielroe committed May 16, 2023
1 parent e3af772 commit 53bd8a4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/nuxt/src/pages/runtime/plugins/router.ts
Expand Up @@ -186,7 +186,7 @@ const plugin: Plugin<{ router: Router }> = defineNuxtPlugin({
if (process.server && failure?.type === 4 /* ErrorTypes.NAVIGATION_ABORTED */) {
return
}
if (to.matched.length === 0) {
if (to.matched.length === 0 && (!process.server || !nuxtApp.ssrContext?.islandContext)) {
await nuxtApp.runWithContext(() => showError(createError({
statusCode: 404,
fatal: false,
Expand Down

0 comments on commit 53bd8a4

Please sign in to comment.