Render HTML Elements to the DOM - FrontEnd Dev Libraries

Tell us what’s happening:

I get the following error when trying to submit:

“Build error, open your browser console to learn more.
Uncaught ReferenceError: ReactDOM is not defined”

  **Your code so far**

const JSX = (
<div>
  <h1>Hello World</h1>
  <p>Lets render this to the DOM</p>
</div>
);
// Change code below this line
ReactDOM.render(JSX, document.getElementById("challenge-node"));

  **Your browser information:**

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/98.0.4758.102 Safari/537.36

Challenge: Render HTML Elements to the DOM

Link to the challenge:

That seems most odd. Your code passes fine for me.

Sometimes things glitch. Reboot, reset the browser cache, and/or try a different browser. I don’t think a browser extension could cause this, but I don’t know. I don’t think security settings would cause this but I don’t know.

1 Like

Hi kevinSmith,
I completed this challenge on my phone using Chrome. It went well.

But in “Render a Class Component to the DOM”, I encountered it again. So I reset the cache on my browser, like you suggested, and it worked fine.

Thanks a lot!

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.