create-react-app
                                
                                 create-react-app copied to clipboard
                                
                                    create-react-app copied to clipboard
                            
                            
                            
                        After upgrading to React 18 version and CRA 5 can not make a build
My React application code compiled successfully but when hit yarn build  command failed with following error.
Module not found: Error: Can't resolve 'D:/projects/updateui/node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/regeneratorRuntime.js' in 'D:\projects\updateui\src\components'
I have upgrade my application React 16 and CRA 4 to React 18 and CRA 5. Any suggestion will be appreciated.
delete the node_modules and lock file and then npm install
check this as well // Before import { render } from 'react-dom'; const container = document.getElementById('app'); render(<App tab="home" />, container);
// After import { createRoot } from 'react-dom/client'; const container = document.getElementById('app'); const root = createRoot(container); // createRoot(container!) if you use TypeScript root.render(<App tab="home" />);