A Pen by Rajat Saxena on CodePen.
Created
October 4, 2018 18:13
-
-
Save mohammadobaid1/f46e2cf1db8d16143939897d9bf6cbd4 to your computer and use it in GitHub Desktop.
MrNmBM
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Our React app will be rendered inside this div --> | |
<div id="root"></div> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Setup | |
// ----- | |
// Click on "Settings" button and look into "JavaScript" settings, I've selected Babel preprocessor and imported two libraries i.e. React and ReactDOM | |
// ReactDOM is a library which provides us with the glue code to between the browser and React.js. | |
ReactDOM.render(<div>Welcome to a React.js Tut</div>, document.getElementById('root')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script src="https://cdnjs.cloudflare.com/ajax/libs/react/15.6.1/react.min.js"></script> | |
<script src="https://cdnjs.cloudflare.com/ajax/libs/react/15.6.1/react-dom.min.js"></script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment