This video explains __proto__ in JavaScript in less than 5 minutes https://www.youtube.com/watch?v=hB7lNOCN2e8&feature=youtu.be
Author Archives: Dhananjay Kumar
Union and Intersection of types in TypeScript
Do you know, TypeScript allows union and Intersection of types? Why you need that? Let us assume you need to create a function that checks whether the passed value is boolean true and returns true, otherwise returns null. That function may look like below, function trueOrNull(foo: any): any { if (foo === true) { return true; } return undefined; } console.log(trueOrNull(88)); // null As you see, theContinueContinue reading “Union and Intersection of types in TypeScript”
Video – Step by Step Create Node.js REST API with SQL Server Database
In this video, learn to create a Node.js API to perform CRUD operations on a database in SQL Server. https://www.youtube.com/watch?v=Uvy_BlgwfLI You can find the source code here : https://github.com/debugmodedotnet/sqlservernodejsrestapi For notifications of the further videos, subscribe to the <geek97/> Youtube channel here : https://www.youtube.com/c/geek97
Master RxJS: Part 2 – What is an observer
This is the second post in the Master RxJS series. The first post is a video tutorial that explains, why RxJS Watch it here: https://www.youtube.com/watch?v=GfuGIh-Bmxw In this post, we will discuss an observer in RxJS. An observer is an object with three call-back functions to subscribe to the notifications from an Observable. Too much technicalContinueContinue reading “Master RxJS: Part 2 – What is an observer”
How to make the length of an Array read-only in JavaScript
Sometimes, you may come across a requirement that once the array is created, its length should not be changed. In this blog post, let us explore how you can achieve that. Let us say you have an array as shown below, let foo = ['1', '11']; console.log(foo.length); // 2 console.log(foo[1]); //11 As you see, the length of the array is 2, andContinueContinue reading “How to make the length of an Array read-only in JavaScript”
Change Detection in Angular
Change Detection is the backbone of the Angular framework, and each component has its own change detector. This article explains change detection strategies and optimizations to help you write highly performant Angular applications. Angular can detect when data changes in the component, and can re-render the view to display the updated data. Angular makes sureContinueContinue reading “Change Detection in Angular”
Video- Master 3 important concepts of JavaScript
In this webinar learn 3 most important concepts of JavaScript. How to calculate the value of ‘this’ inside a function All about object literals function constructors and prototypes https://www.youtube.com/watch?v=F2V7MgehDSY
Link Constructors prototypes to create Inheritance in JavaScript
In JavaScript, there are multiple ways to create an object. However, among all the most popular is using a function as a constructor. A function returns a newly created object if it is called using the new, which is also known as Constructor Invocation Pattern. You can create a function constructor like any otherContinueContinue reading “Link Constructors prototypes to create Inheritance in JavaScript”
How Object.entries work internally in JavaScript
In JavaScript, the Object.entries method returns an array of object’s own enumerable properties. It returns properties as a [key, value] pair, where the key is a string. You can read enumerable properties as an array of key-value pairs using the Object.entries method as shown below, let Product = { Title: ‘Book’, Price: 120, Author: undefined, inStock: true } console.log(Object.entries(Product)); Since it returnsContinueContinue reading “How Object.entries work internally in JavaScript”