We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hash history 模式下,在独立页面中打开 demo,将跳转到 404
原因为 demoLink 中未携带 # 号
目前本地修复方式为复写 slots/PreviewerActions,手动处理 demoUrl,不过感觉可能最好是在生成 demoUrl 的地方处理最好
// .dumi\theme\slots\PreviewerActions.tsx import React, { useMemo } from 'react' import PreviewerActions, { IPreviewerActionsProps } from 'dumi/theme-default/slots/PreviewerActions' export default function OverridedPreviewerActions({ demoUrl, ...props }: IPreviewerActionsProps) { const fixedDemoUrl = useMemo(() => demoUrl.replace(/\/~demos\//, `${window.location.pathname}#/~demos/`), [demoUrl]) return <PreviewerActions {...props} demoUrl={fixedDemoUrl} /> }
The text was updated successfully, but these errors were encountered:
dumi 2 目前是不支持 hash 模式的,hash 模式问题统一合并到一个 issue 讨论吧
Sorry, something went wrong.
Duplicate of #1553
No branches or pull requests
hash history 模式下,在独立页面中打开 demo,将跳转到 404
原因为 demoLink 中未携带 # 号
目前本地修复方式为复写 slots/PreviewerActions,手动处理 demoUrl,不过感觉可能最好是在生成 demoUrl 的地方处理最好
Versions
Steps to reproduce
What is Expected?
What is actually happening?
The text was updated successfully, but these errors were encountered: