Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update cra-template for react18 #12226

Closed
wants to merge 2 commits into from
Closed

Conversation

winterlood
Copy link

CRA install react template that use react 18 version

so we should update DOM API ReactDOM.render() -> ReactDOM.createRoot()

@winterlood winterlood reopened this Apr 2, 2022
import './index.css';
import App from './App';
import reportWebVitals from './reportWebVitals';

ReactDOM.render(
const rootElment = document.getElementById('root') as HTMLElement
Copy link

@kode15333 kode15333 Apr 3, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
const rootElment = document.getElementById('root') as HTMLElement
const rootElement = document.getElementById('root') as HTMLElement

I think this is a typo 🤣

@minimabot
Copy link

It seems a duplicate of #12220.

@winterlood winterlood closed this Apr 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants