Skip to content
New issue

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

SSR页面标题渲染失败 #5118

Closed
zfhslfgit opened this issue Jul 28, 2020 · 6 comments · Fixed by #5486
Closed

SSR页面标题渲染失败 #5118

zfhslfgit opened this issue Jul 28, 2020 · 6 comments · Fixed by #5486
Assignees
Labels

Comments

@zfhslfgit
Copy link

zfhslfgit commented Jul 28, 2020

最小可复现仓库

https://github.com/zfhslfgit/ssr-with-eggjs-test

标题SSR渲染失败

内容能正常服务端渲染,但标题不行(用户能正常显示标题,就是SEO的标题异常)。
图片

图片

image

相关环境信息

umi:3.2.9
node: 10.16.3

@xiaohuoni xiaohuoni added the type(ssr) UmiJS SSR label Jul 29, 2020
@supwjm
Copy link

supwjm commented Jul 29, 2020

虽然没有找到具体原因,不过example/ssr-koa 那个例子,我把渲染模式mode 从stream 改成string就好了https://blog.csdn.net/supming1/article/details/107523129

@shlomitsur
Copy link

I have the same issue, the Helmet plugin is not called for mode='stream'?

@shlomitsur
Copy link

I have the same issue too.

@ycjcl868
Copy link
Contributor

image

test case reproduce, fixing ...

@ycjcl868
Copy link
Contributor

ycjcl868 commented Sep 27, 2020

nfl/react-helmet#322

This means if you're using ReactDOMServer.renderToNodeStream(), ReactDOMServer.renderToStaticNodeStream(), Apollo Client's getDataFromTree or any other form of asynchronous rendering, you should not use react-helmet.

@sandmanman
Copy link

请问有人解决了吗,现在还是这个情况。umi -> 3.2.25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants