Fix [Object object] in MDX output (#4180)
* fix: use stringifyChunk in `renderToString` fn * chore: add changeset Co-authored-by: Nate Moore <nate@astro.build>
This commit is contained in:
parent
c9b679e56e
commit
c56a9227c7
2 changed files with 6 additions and 1 deletions
5
.changeset/purple-mirrors-smile.md
Normal file
5
.changeset/purple-mirrors-smile.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
'astro': patch
|
||||
---
|
||||
|
||||
Fix edge case where Astro component would render [Object object] when using MDX
|
|
@ -752,7 +752,7 @@ export async function renderToString(
|
|||
|
||||
let html = '';
|
||||
for await (const chunk of renderAstroComponent(Component)) {
|
||||
html += chunk;
|
||||
html += stringifyChunk(result, chunk);
|
||||
}
|
||||
return html;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue