React Markdown Previewer Project Not Working

I’ve been working on this project but I can’t seem to get the actual preview to appear on the main screen from my code. I’ve tried fixing my error in JavaScript but I’m not even sure why the error is there.
What am I doing wrong?
Here’s the link to my CodePen:

You’re getting two errors: First, an unterminated string constant. Use the backtick character ( ` ) to wrap your string, if you want multi lines.

Second, your div on line 27 is not properly closed.

Least, that’s how it looks from MY porch. :wink:

Does the React-production you’re including also include React-DOM, or do you need to include that as well. After fixing the two errors I’d mentioned, I noticed you’re also getting a ReactDOM not loaded error.

Thanks! I fixed all the errors but the screen is still blank. I did include React-DOM but still nothing.
Here’s the link: https://codepen.io/donnacamos88/pen/MPKwzQ?editors=0011

Did you load React on Codepen? It looks like your Codepen project isn’t recognizing React at all.

I’m pretty sure I did. I went into the settings on JavaScript and typed “React” into the search box. It pulled up react and react-DOM. The tutorial I’m going through said to use react-DOM so that’s what I put in. Why doesn’t it recognize it? Am I missing something with React?

You should probably stop using Codepen for React/Javascript projects. If you’re that far along it’s time to use an IDE or text editor like Atom, VS, Sublime, etc…

Way easier to work on something that way. Use create-react-app for React projects. Much better than messing around with Codepen.

Thanks for the advice. I’m just going to download Sublime and start over. Maybe I can get better results from there.

@snowmonkey I had the same issue. I was using regular quotes in the project and couldn’t figure it out for the life of me. Your suggestion with using the backtick character worked in my case. Thanks for your input.

1 Like