Year: 2013
-
Revealing Module Pattern in JavaScript
We talked about Prototype Pattern in previous posts. You can read them at below link. Understanding Prototype Pattern in JavaScript Understanding Prototype Pattern in JavaScript: Part # 2 Revealing Module Pattern allows us to achieve Singleton object Private Public behaviour of functions and properties in the object. Let us consider the usual code we write.…
-
Understanding Prototype Pattern in JavaScript: Part # 2
Recently we had a look on Understanding Prototype Pattern in JavaScript. I tried to explain this pattern in most simplified way. In this post we will get more dipper and see how prototype works in JavaScript. Putting it in simple words in prototype pattern, we create object using template of an existing object. In prototype…
-
Understanding Prototype Pattern in JavaScript
I am writing this blog post from Bulgaria Sofia. I am here to attend Devreach conference organised by Telerik . In conference I had an opportunity to meet my great inspiration Dan Wahlin . I attended his session on “Patterns in JavaScript” and I must say it was one of the best technical session I…
-
Variable Scope Chain in JavaScript
Before you start reading this post I recommend you to read Variable Scoping and Hoisting in JavaScript . In this post we will take a look on Scope Chain in JavaScript. Let us consider you have declare a variable globally as below, In above code variables are declared globally, in other words they are not…
-
Get it right: null and undefined in JavaScript
Well, whenever I talk to developers, I find them in confusion about null and undefined in JavaScript. In this post I try to simplify understanding of null and undefined in JavaScript. To start with null is language keyword and undefined in value of a variable. Both evaluates to value that indicates absence of a value.…
-
Single Responsibility Principle in C-Sharp: Simplified
Let us start with understanding what is SRP? Single Responsibility Principle says every class should have single responsibility and all the responsibility should be encapsulated in the class. To explain it further assume you are creating a creating class to Calculate Salary. Now if you have two methods in class like below. Usually we can…
-
Variable Scoping and Hoisting in JavaScript
Variable Scoping in JavaScript is quite different than other programming languages like C. In this post we will learn variable scoping in JavaScript. Simply putting, Scope of a JavaScript variable is within region of the program it is defined. So a variable defined inside function will have scope inside that function. Consider following code snippet,…
-
Invocation patterns in JavaScript
In JavaScript you can invoke a function in four different ways. In this post we will take a look on various invocation patterns. There are four ways a function can be invoked in JavaScript. Four invocation patterns in JavaScript are as follows, Function Invocation Pattern Method Invocation Pattern Constructor Invocation Pattern Indirect Invocation Pattern Function…
-
Presented on Backend as a Service in Pune DevCon 2013
On 24th Aug 2013 I presented on Backend as a Service in Pune DevCon 2013. It was one of the premium event with more than 300 attendees and 25 speakers. I had an opportunity to present on Backend as a Service under Windows 8 track. I had a very humble audience of 30 people. I…
-
CRUD operation on ASP.NET Web API from .NET client
In this post we will learn to work with CRUD operation on ASP.NET Web API. We will learn To create CRUD operation on ASP.NET Web API Using Entity model to create model Creating repository to perform CRUD operation Consuming service in .NET Console Client I can draw architecture of this blog post as following, Let…