-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathindex.html
More file actions
31 lines (26 loc) · 922 Bytes
/
index.html
File metadata and controls
31 lines (26 loc) · 922 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<!DOCTYPE html>
<html lang="en">
<meta charset="utf-8" />
<title>React Form</title>
<body>
<!-- These scripts will make React and ReactDOM globally available. -->
<div id="root"></div>
<script crossorigin src="https://unpkg.com/react@18/umd/react.development.js"></script>
<script crossorigin src="https://unpkg.com/react-dom@18/umd/react-dom.development.js"></script>
<script src="https://unpkg.com/@babel/standalone/babel.min.js"></script>
<script type="text/babel">
const container = document.getElementById('root');
const TempConverter = () => {
return (
<form>
<h1>Temperature converter</h1>
<output>converted output goes here</output>
</form>
);
};
const App = () => <TempConverter />;
const root = ReactDOM.createRoot(container);
root.render(<App />);
</script>
</body>
</html>