Skip to content

fix: SSR render prefetched React embeds#8

Merged
markbang merged 1 commit into
mainfrom
feat/react-ssr-prefetch
Mar 31, 2026
Merged

fix: SSR render prefetched React embeds#8
markbang merged 1 commit into
mainfrom
feat/react-ssr-prefetch

Conversation

@markbang
Copy link
Copy Markdown
Owner

@markbang markbang commented Mar 31, 2026

Summary

  • render pre-fetched MemoEmbed and MemoEmbedList markup during SSR/SSG instead of waiting for hydration
  • replace imperative innerHTML injection with direct render output and memoized HTML generation
  • add server-render regression tests and document the SSR behavior

Testing

  • pnpm validate

Summary by cubic

Server-renders pre-fetched MemoEmbed and MemoEmbedList in @memos-embed/react so SSR/SSG pages include full embed HTML without waiting for hydration. Also replaces innerHTML injection with direct render output for safer, faster markup.

  • Bug Fixes
    • SSR/SSG now outputs full embed HTML when memo/memos props are provided.
    • Removed imperative innerHTML; use memoized HTML and a small renderHtml helper.
    • Added SSR regression tests and updated docs/READMEs; published a patch changeset.

Written for commit a121dfc. Summary will update on new commits.

@vercel
Copy link
Copy Markdown

vercel Bot commented Mar 31, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
memos-embed-site Ready Ready Preview, Comment Mar 31, 2026 6:57am

Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 5 files

@markbang markbang merged commit f07cde8 into main Mar 31, 2026
4 checks passed
@markbang markbang deleted the feat/react-ssr-prefetch branch March 31, 2026 06:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant