We cannot use HTML comments inside of JSX because it thinks they are real DOM Nodes:
render() {
return (
<div>
<!-- This doesn't work! -->
</div>
)
}
We can use regular /* Block Comments */, but this need to be wrapped in curly braces:
{/* A JSX comment */}
render() {
return (
<div>
<!-- This doesn't work! -->
</div>
)
}
We can use regular /* Block Comments */, but this need to be wrapped in curly braces:
{/* A JSX comment */}