Ben's Blog A place to share my thoughts

NDepend - Static Code Analysis

Over the past few months, I have been trialling a number of different tools to help me improve code quality. However, static code analysis it’s something that I was yet to use… until now!

Read more

Async Programming in .NET: Part 3

Now that we’ve covered the foundations along with an introduction on how we write async code in C#, this article will focus on the best practices for async programming!

Read more

Async Programming in .NET: Part 2

Following on from part 1, in this post I will discuss in detail how to write async code in C#.

As a recap, asynchronous code essentially helps to remove performance bottlenecks and improve responsiveness of the application. It’s ideal for any scenario where your application is subject to blocking (I/O bound). Many APIs in .NET already support async programming (HttpClient, StreamWriter,StreamReader etc), but one might wonder why it’s not used everywhere (Node.js anyone?).

Read more

Async Programming in .NET: Part 1

I’ve been using the async and await keywords at work on both our .NET core API and Xamarin projects, but I started to feel guilty as I didn’t fully understand how asynchronous code works in the .NET framework. This post is mostly to help me put into my own words what async programming really is (and why I now think it’s awesome).

Read more

Roslynator and Intellicode

I have been experimenting with Resharper. It’s my first time using it (with VS Professional 2017), and have concluded that it’s quite a remarkable piece of software with an incredible number of features. Using resharper is a bit like having an opinionated buddy constantly looking at your code and providing you with useful hints, whilst automating and providing shortcuts to some of the more tedious jobs i.e. extracting code into a new method.

Read more