JavaScript & DOM Event Handlers
During end of last year we faced some serious browser memory leak issues in one of our projects.As we dug deep into the problem we found that event handlers were not detached from the HTML elements...
View ArticleC# 6.0 – nameof Operator
In this post, we will discuss about the C# 6.0 nameof operator. In the code snippet below we are trying to the details i.e Class & method names whenever a method is invoked. In real life...
View ArticleTuples in C#7
What is a tuple ? - A tuple is an ordered group of elements. Tuple has been there as a data type in most of the functional programming languages like Lisp , Haskell since their inception. For example...
View ArticleDeconstruction in C#7.0
In my earlier blog post related to Tuples, I had used the following two ways for accessing the elements of the tuple. The first one is obviously inefficient and to be honest wrong, there is no point...
View ArticleLocal Functions in C#7.0
The nested functions (methods) or local functions are functions defined inside another function , referred to as the enclosing function. The nested functions are available only within the scope of the...
View ArticleRequest Processing in ASP.NET Core
ASP.NET Web Forms were launched as part of .NET Framework 1.0 in 2002. It was a logical evolution from ASP, moving away from interpreted web pages with dependency on a scripting engine, towards type...
View ArticleASP.NET Core Application Startup – Part1
In the last post we have discussed on how the ASP.NET Core request processing pipeline works. As a next step, let’s take a closer look into how the ASP.NET Core application gets started and...
View ArticleASP.NET Core Application Startup – Part2
In the last post we found that the Startup class in ASP.NET Core works based on convention. The runtime inspects the class through reflection and invokes the appropriate methods i.e. Configure and...
View ArticleControl Expressions in Kotlin
In any imperative programming language, an expression is a line or fragment of code that is computed to produce a value whereas statement is a standalone unit of the program which intends to perform...
View ArticleASP.NET Core Middleware–Part 1
In one of my earlier post, I have discussed in details about the ASP.NET Core request processing and the key components involved i.e reverse proxy, ASP.NET Core Web Server and the ASP.NET Core...
View ArticleMemoization Using C#
Memoization is a technique very commonly used in Functional Programming to improve the performance of a function execution by caching its results. Here, caching helps to avoid the expensive...
View ArticleASP.NET Core Middleware Part – II
In the last post we have discussed the basics of ASP.NET Core Middleware and how it fits into the request processing pipeline. As a next step we will see how we can build the middleware pipeline using...
View Articlemodule.exports vs exports in Node.js
Let’s start by developing a simple ( or sample) Node module as shown below. The file mymodule.js contain the following lines of code to expose two functions with the properties a and b using the...
View ArticleCircular Dependency in Node.js Modules
In this post we will examine how the module initialization in Node.js is affected by the circular dependencies ( we will restrict this discussion to the CommonJS specification based module system) I...
View ArticleCircular Dependency in Node.js ES Modules
In the previous post we had discussed about circular dependency in Node.js modules using CommonJS modules specification.Here we will examine the behaviour of Node.js modules using ES Module...
View ArticleCallback Hell in Node.js/JavaScript
A callback is a function which is passed as an argument to another function and invoked with the results generated after that function execution is completed. The result is propagated to the callback...
View ArticleAsynchronous Control Flow in Node.js with async Library
The two common asynchronous control flow patterns include sequential and parallel flows. In the sequential flow, the tasks are executed one after the other in sequence and delay in one causes a delay...
View ArticlePromise in JavaScript / Node.js–Part1
As we have discussed earlier callbacks are the basic building blocks of asynchronous programming in JavaScript/Node.js , they are used for notifying when an asynchronous operation is completed. But...
View ArticlePromise in Node.js / JavaScript–Part II
In the previous post, we have discussed about the basics of Promise, here we will take a deeper look into the Promise.then function. The code below shows the promisified version of the add function...
View ArticlePromise in Node.js / JavaScript–Part III
In the previous post, we have seen Promises can be chained together by returning another Promise object from the onFulfilled parameter of the then function. The chain of Promises executes sequentially....
View Article