Skip to content

Commit a300033

Browse files
committed
fix: solve for potential unmounting issue when re-running rehydrate
1 parent b5d47bb commit a300033

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

docs/demos/components/MarkupContainer/MarkupContainer.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,11 @@ class MarkupContainer extends React.Component {
5858

5959
return (
6060
<div ref={this.mainRef}>
61-
{markup.map((__html, i) => (
61+
{markup.map((node, i) => (
6262
<div
63-
data-react-from-markup-container
64-
dangerouslySetInnerHTML={{ __html }}
63+
dangerouslySetInnerHTML={{
64+
__html: `<div data-react-from-markup-container>${node}</div>`
65+
}}
6566
key={i}
6667
/>
6768
))}

0 commit comments

Comments
 (0)