Concurrent mode
Building responsive web apps with Prabashwara Seneviratne (bash)
Concurrent mode Prabashwara Seneviratne (bash) Before we start - - PowerPoint PPT Presentation
Building responsive web apps with Concurrent mode Prabashwara Seneviratne (bash) Before we start Disclaimers In a nutshell What is it? For react, this the ability to work on multiple state updates at the same time Incremental Adoption
Building responsive web apps with Prabashwara Seneviratne (bash)
Before we start
For react, this the ability to work on multiple state updates at the same time
In a nutshell
Incremental
ReactDOM.render(<App />, rootNode) ReactDOM.createRoot(rootNode).render(<App />) Blocking Mode
ReactDOM.createRoot(rootNode).render(<App />)
Introducing A JS framework aggregator to keep track of all the JS frameworks created everyday
Problem #1
Problem #1 Detail page fetches its data first Then the cards will render and start fetching their data
Problem #1
Previously on React 16.6 Split javascript code into multiple files so that only what is required by the client would be downloaded
Coming up: the all new, fully extended Components can use special loaders which will start running straightaway, regardless of the structure
The new suspense
The
Problem #2 The app changes state instantly - which leads to an ugly loading spinner while next data loads
The new solution useTransition lets you show the current state while react works on the next one in the background
withTransition
Time for The “unsafe” lifecycle methods are really unsafe now Old context API, string refs and findDOMNode are dead ReactDOM.findDOMNode(component)
bash2/package-pile me@bash.lk @MewsDevs https://developers.mews.com