Replies: 2 comments
-
How to load react web app faster? To deploy React App, we need to build the app and combine all components and CSS files into minified versions, which convert them into respective bundles!
Also, you need to configure gzip on the webserver to start serving bundle.js.gz instead bundle.js |
Beta Was this translation helpful? Give feedback.
-
React Lifecycle discussion (function based)1) ComponentDidMount():- Equivalent in function based react is useEffect hook with empty dependency. The component is rendered only once after being mounted once.
2) ComponentDidUpdate():- the component is Re-rendered after updates to props or states is performed.
In the above example, whenever the value of page state is changed, the component is re-rendered. 3) ComponentWillUnmount():- Called just before the component is unmounted or destroyed.
In the above, example as the component mounts, the timing variable comes into picture and just before the component is destroyed, the code written in 'return' statement runs i.e clearing out the timing variable. |
Beta Was this translation helpful? Give feedback.
-
Hello, Everyone.
Let's discuss experience of React together here.
Welcome!!!
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions