Closed
Description
React will issue a warning if you try to use dangerouslySetInnerHTML and children at the same time.
https://github.com/facebook/react/blob/85dcbf83/src/renderers/dom/shared/ReactDOMComponent.js#L170
This should be easy enough to enforce for most cases with a linter rule.
Bad:
<div dangerouslySetInnerHTML={{ __html: 'HTML' }}>
Children
</div>
Good:
<div dangerouslySetInnerHTML={{ __html: 'HTML' }} />
<div>
Children
</div>