-
Book Overview & Buying
-
Table Of Contents
Full-Stack React, TypeScript, and Node - Second Edition
By :
JavaScript is known as an Object Oriented Programming language. However, JavaScript's implementation is limited when compared to TypeScript. In this section, we'll take a look at how JavaScript does OOP and how TypeScript improves upon JavaScript's capabilities.
First, let's list the four pillars of Object Oriented Programming. Although various combinations of three or four principles, including Modularity and Hierarchy, have been proposed over the years, the widely accepted modern list is:
Let's review each one.
An easier phrase for understanding encapsulation might be information hiding. In every program you will have data, and methods that allow you to do something with that data. When we use encapsulation, we are taking that data and putting it into a container of sorts. This container is known as a class in most programming languages and basically, it protects...
Change the font size
Change margin width
Change background colour