From bb9e8a173dff6c0c086ecc09b116d0258edf8cb8 Mon Sep 17 00:00:00 2001 From: Innei Date: Sun, 29 Oct 2023 19:33:23 +0800 Subject: [PATCH] fix(storybook): use hash router Signed-off-by: Innei --- README.md | 2 +- storybook/src/router.tsx | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 2e5138729d..3c1afc0b67 100644 --- a/README.md +++ b/README.md @@ -86,7 +86,7 @@ docker run --name shiro -d -p 2323:2323 shiro ## Markdown 扩展语法 -请阅读 https://shiro.innei.in/markdown +请阅读 https://shiro.innei.in/#/markdown ## :heart: 鸣谢 & 许可 diff --git a/storybook/src/router.tsx b/storybook/src/router.tsx index 899184ac78..84d6871bc9 100644 --- a/storybook/src/router.tsx +++ b/storybook/src/router.tsx @@ -1,6 +1,6 @@ import { createElement, Suspense } from 'react' import { ErrorBoundary } from 'react-error-boundary' -import { createBrowserRouter } from 'react-router-dom' +import { createHashRouter } from 'react-router-dom' import type { RouteObject } from 'react-router-dom' import { @@ -34,7 +34,7 @@ children.push({ Component: Debug, name: 'debug', }) -export const routes = createBrowserRouter([ +export const routes = createHashRouter([ { path: '/', Component: Root,