Skip to content

Commit f82dc3d

Browse files
committed
update to react 18
1 parent 85f369b commit f82dc3d

13 files changed

+34669
-31639
lines changed

public/index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@
2222
<noscript>You need to enable JavaScript to run this app.</noscript>
2323
<div id="root"></div>
2424

25-
<!-- https://unpkg.com/react@17.0.2/umd/react.production.min.js -->
25+
<!-- https://unpkg.com/react@18.2.0/umd/react.production.min.js -->
2626
<script type="module" src="lib/react.production.min.js"></script>
27-
<!-- https://unpkg.com/react-dom@17.0.2/umd/react-dom.production.min.js -->
27+
<!-- https://unpkg.com/react-dom@18.2.0/umd/react-dom.production.min.js -->
2828
<script type="module" src="lib/react-dom.production.min.js"></script>
2929

3030
<script type="module" src="src/index.js"></script>

public/lib/react-dom.production.min.js

+256-234
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/lib/react.production.min.js

+23-23
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/src/index.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@ import { React, ReactDOM, html } from './imports.js';
22
import App from './App.js';
33
// import reportWebVitals from './reportWebVitals.js';
44

5-
ReactDOM.render(
5+
const root = ReactDOM.createRoot(document.getElementById('root'));
6+
root.render(
67
html`
78
<${React.StrictMode}>
89
<${App} />
910
<//>
10-
`,
11-
document.getElementById('root')
11+
`
1212
);
1313

1414
// If you want to start measuring performance in your app, pass a function

public/src/reportWebVitals.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
const reportWebVitals = onPerfEntry => {
22
if (onPerfEntry && onPerfEntry instanceof Function) {
3-
import('https://unpkg.com/[email protected].2/dist/web-vitals.js').then(
3+
import('https://unpkg.com/[email protected].4/dist/web-vitals.js').then(
44
({ getCLS, getFID, getFCP, getLCP, getTTFB }) => {
55
getCLS(onPerfEntry);
66
getFID(onPerfEntry);

public/test/index.html

+7-7
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,21 @@
77
<!-- make paths relative to parent folder -->
88
<base href="../" />
99

10-
<!-- https://unpkg.com/mocha@9.1.3/mocha.css -->
10+
<!-- https://unpkg.com/mocha@9.2.2/mocha.css -->
1111
<link rel="stylesheet" href="test/lib/mocha/mocha.css" />
1212

1313
<!-- development build of react needed for unit tests -->
14-
<!-- https://unpkg.com/react@17.0.2/umd/react.development.js -->
14+
<!-- https://unpkg.com/react@18.2.0/umd/react.development.js -->
1515
<script src="test/lib/react/react.development.js"></script>
16-
<!-- https://unpkg.com/react-dom@17.0.2/umd/react-dom.development.js -->
16+
<!-- https://unpkg.com/react-dom@18.2.0/umd/react-dom.development.js -->
1717
<script src="test/lib/react/react-dom.development.js"></script>
18-
<!-- https://unpkg.com/react-dom@17.0.2/umd/react-dom-test-utils.development.js -->
18+
<!-- https://unpkg.com/react-dom@18.2.0/umd/react-dom-test-utils.development.js -->
1919
<script src="test/lib/react/react-dom-test-utils.development.js"></script>
20-
<!-- https://unpkg.com/[email protected].4/chai.js -->
20+
<!-- https://unpkg.com/[email protected].6/chai.js -->
2121
<script src="test/lib/mocha/chai.js"></script>
22-
<!-- https://unpkg.com/mocha@9.1.3/mocha.js -->
22+
<!-- https://unpkg.com/mocha@9.2.2/mocha.js -->
2323
<script src="test/lib/mocha/mocha.js"></script>
24-
<!-- https://unpkg.com/@testing-library/dom@8.11.1/dist/@testing-library/dom.umd.js -->
24+
<!-- https://unpkg.com/@testing-library/dom@8.17.1/dist/@testing-library/dom.umd.js -->
2525
<script src="test/lib/@testing-library/dom.umd.js"></script>
2626
</head>
2727

0 commit comments

Comments
 (0)