From 4a6eda48704ad34e003d144594bbc56c1b448c6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roman=20Ondr=C3=A1=C4=8Dek?= Date: Sun, 14 Aug 2022 18:31:08 +0200 Subject: [PATCH] fix(theme): fix custom NotFound component rendering (#1163) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Roman Ondráček Co-authored-by: Divyansh Singh <40380293+brc-dd@users.noreply.github.com> --- src/client/app/index.ts | 2 +- src/client/theme-default/components/VPContent.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/client/app/index.ts b/src/client/app/index.ts index 7fcfc53a95a7..50158d611374 100644 --- a/src/client/app/index.ts +++ b/src/client/app/index.ts @@ -16,7 +16,7 @@ import { dataSymbol, initData } from './data' import { Content } from './components/Content' import { ClientOnly } from './components/ClientOnly' -const NotFound = Theme.NotFound || (() => '404 Not Found') +export const NotFound = Theme.NotFound || (() => '404 Not Found') const VitePressApp = { name: 'VitePressApp', diff --git a/src/client/theme-default/components/VPContent.vue b/src/client/theme-default/components/VPContent.vue index dddf39ca93f9..f0a04e1a780f 100644 --- a/src/client/theme-default/components/VPContent.vue +++ b/src/client/theme-default/components/VPContent.vue @@ -2,7 +2,7 @@ import { useRoute, useData } from 'vitepress' import { useCopyCode } from '../composables/copy-code' import { useSidebar } from '../composables/sidebar' -import NotFound from '../NotFound.vue' +import { NotFound } from '../../app' import VPPage from './VPPage.vue' import VPHome from './VPHome.vue' import VPDoc from './VPDoc.vue'