silence react warning when showing edited marker, by also giving the body a key

pull/21833/head
Bruno Windels 2019-05-17 13:31:26 +01:00
parent 4c94b398d3
commit 76ceee0e6c
1 changed files with 2 additions and 2 deletions

View File

@ -541,8 +541,8 @@ export function bodyToHtml(content, highlights, opts={}) {
});
return isDisplayedWithHtml ?
<span className={className} dangerouslySetInnerHTML={{ __html: safeBody }} dir="auto" /> :
<span className={className} dir="auto">{ strippedBody }</span>;
<span key="body" className={className} dangerouslySetInnerHTML={{ __html: safeBody }} dir="auto" /> :
<span key="body" className={className} dir="auto">{ strippedBody }</span>;
}
export function emojifyText(text, addAlt) {