DOM VS VIRTUAL DOM VS SHADOW DOM

Apr 20

DOM VS VIRTUAL DOM VS SHADOW DOM

As most of you know DOM refers to DOCUMENT OBJECT MODEL which is nothing but the Nested Tree structure of the HTML / XML code.→ Each node in the tree is an Object representing HTML elements.→ DOM allows HTML code to connect with JavaScript, DOM can be manipulated directly (i.e) documet.getElementById().The workflow of Web Browers→ DOM tree itself is constructed by the rendering engines.→ Now the CSS is applied to HTML creating the render tree.→ Now the render tree is painted in the browser.Now Updating this tree becomes Expensive, to overcome this frameworks like React, Vue, Angular, etc uses

Apr 20

Why Coding Splitting In React Apps

Code splitting helps in Increasing the Efficiency of the App by reducing the loading time of the browersFirst of all why code-splitting?In React Apps Everything is bundled. File budling is the process of merging and importing all files into one single file. For budling, files React using Webpack.Now comes the question of why bundling the files?Bundling your files helps in optimization and reduces the time it takes for your page to load because the browser doesn’t have to run separate files while loading the web app.Okay, then Bundling helps the browsers to run the App fast then why code splitt

Apr 20

Life Cycle in React JS

In React Everything has a lifecycle that can be observed or controlled during three phasesMountingUpdatingUnmountingMountingconstructorgetDerivedStateFromStaticPropsrendercomponentDidMountUpdatingshouldComponentUpdatecomponentDidUpdategetSnapShotBeforeUpdaterenderUnmountcomponentWillUnmountApart from this, we havecomponentDidCatch(To Catch Error)