Created
July 8, 2021 11:53
-
-
Save vuldin/1107d57f8f9b91b698e1deff2e8c4205 to your computer and use it in GitHub Desktop.
An HTML file that uses Babel to display a simple React component
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<title>Simple React</title> | |
<meta charset="utf-8" /> | |
<link rel="shortcut icon" href="data:image/x-icon;," type="image/x-icon" /> | |
<script src="https://unpkg.com/react@17/umd/react.development.js"></script> | |
<script src="https://unpkg.com/react-dom@17/umd/react-dom.development.js"></script> | |
<script src="https://unpkg.com/[email protected]/babel.min.js"></script> | |
</head> | |
<body> | |
<div id="root"></div> | |
<script type="text/babel"> | |
function Hello() { | |
return <h1>Hello</h1> | |
} | |
ReactDOM.render(<Hello />, document.getElementById('root')) | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment