Skip to content
replace ef code with dapper

Replacing existing entity framework code with Dapper

Developers choose Entity framework ORM (EF) for better productivity when accessing the database. But, when the product is built that went from bare bones to very complex and heavy data access then comes the performance.

Sometimes its the Entity framework that kills the performance so the choice when searching for a better ORM than Entity framework is Dapper.

In this post, I’ll walk you through how we can replace the existing entity framework code with dapper.

Read More »Replacing existing entity framework code with Dapper

custom 400 responses

Customizing automatic HTTP 400 error response in ASP.NET Core Web APIs

Annotating the controllers with ApiController attribute in ASP.NET Core 2.1 or higher will enable the behavioral options for the API’s. These behavioral options include automatic HTTP 400 responses as well.

In this post, we’ll see how we can customize the default error response from the ASP.NET Core Web API.

Read More »Customizing automatic HTTP 400 error response in ASP.NET Core Web APIs

stack and heap

visualizing stack and heap with SharpLab

When I wanted to look at the IL of the C# code I wrote I used to create a new console application in visual studio and write the code and build it and view the DLL with ILSpy or dotPeek.

These days I’m using LINQPad to view the IL quickly.

Here is the alternative to that hectic setup, Sharplab.

SharpLab is developed by Andrey Shchekin. SharpLab is a similar tool you can use to Run, De-compile (C#, IL, JIT Asm) and visualizing syntax trees. You can also switch the C# language to whatever you want in SharpLab.

And the good thing about SharpLab is that you don’t need any tools except a web browser.

Read More »visualizing stack and heap with SharpLab

preventdefault-vs-stopbubbling

stopPropagation() and preventDefault() in JavaScript

In this article, we’ll see what is stopPropagation and preventDefault in JavaScript.

In the previous blog post, we looked at what event bubbling is and how we can implement it. If you are unaware of what event bubbling is please take a look at my blog post.

To understand stopPropagation and preventDefault in JavaScript, you need a basic understanding of event bubbling.

Read More »stopPropagation() and preventDefault() in JavaScript
event-bubbling

What is Event Bubbling in JavaScript

what is event bubbling? How does event bubbles up? In this post, I’ll explain
how event bubbling happens and how to achieve event bubbling with JavaScript
and jQuery using event delegation. Event delegation is the implementation of
event bubbling.