Archives October 2018

React Components

Components are small, isolated, and reusable parts of UI. Technically, a component is a JavaScript function which takes an input [called props] and returns a React element (JSX). For example: We can also extend React’s Component class to create a class based components, which has some additional features when compared to a function based component.

Read More


Virtual DOM

A Virtual DOM (VDOM) is a concept of displaying UI elements on the webpage without coupling them with the Real DOM (DOM). It is a lightweight JavaScript object, a tree structure similar to the DOM. Using libraries like ReactDOM, we align and display the VDOM on the page; which mounts the entire VDOM on a

Read More


DOM and The Web Page

A concise introduction of how the browser displays a web page. Document Object Model (DOM) is an interface which treats the HTML (or XHTML/XML) as a tree structure. The node of this tree represents an HTML element. The process of rendering a page on the web browser involves many steps. Simply speaking, when we type

Read More


Observer Pattern

According to the GoF book, Design Patterns: Elements of Reusable Object-Oriented Software, the definition of Observer Pattern is: “One or more observers are interested in the state of a subject and register their interest with the subject by attaching themselves. When something changes in our subject that the observer may be interested in, a notify

Read More