Using React on CodePen

How do I get react to work on the codePen JS editor? I tried adding react to the JS file directly from the settings but after using ReactDOM.render() it doesn’t still show on the result page

you also need to select Babel as preprocessor

thats the default preprocessor of JS on codePen

it’s not, the default is “None”

but it’s difficult to know what’s wrong without seeing your project

Okay…thanks. This is my code though


<script src=""></script>

<html lang="en">
    <div id="quote-box">


//React Code
import 'bootstrap/dist/css/bootstrap.min.css';

const quotes = {[Certain things catch your eye, but pursue only those that capture the heart.,You miss 100% of the shots you don’t take.,Life shrinks or expands in proportion to one’s courage.,You can’t fall if you don’t climb. But there’s no joy in living your whole life on the ground.,There are no traffic jams along the extra mile.]};
const authors = {[Ancient Indian Proverb,Wayne Gretzky,Anais Nin,Unknown,Roger Staubach]};

class App extends React.Component{
    this.handleClick = this.handleClick.bind(this);
      <div id="text">{quotes[rand]}</div>
      <div id="author">- {authors[rand]}</div>
      <button id="new-quote">New Quote</button>
      <a id="tweet-quote"><button></button></a>

ReactDOM.render(<App />, document.getElementById("quote-box"));

the JS part isn’t done yet but its still supposed to show the New Quote button