Posts - page 3

Recent posts

Converting a TypeScript project from CommonJS to ESM

July 06, 2024  6 minute read  

I haven’t made much progress on my own projects recently because of a project at work. Specifically, I am currently maintaining a CLI tool written in TypeScript about five years ago. It hasn’t really been looked after on a consistent basis, but some of the libraries that it uses (specifically, update-notifier and wait-on) have some security issues. Now, this is a development CLI tool, so the actual vulnerabilities don’t affect production code. Still, many people don’t like to use tools th...

The State of React UI libraries in 2024

June 27, 2024  7 minute read  

As I mentioned in my last post, I’ve been away from React development for a while, and I’m intending on writing a web application. I’m comparing the various libraries that I can use for my application. In this post, I’m going to be comparing UI component libraries. Thus far, my tech stack is: Base web framework: React Frontend tooling: Vite Hosting: Azure Static Web Apps State management: Redux Toolkit React UI component libraries are collections of ready-to-use UI elements that...

The State of React state management in 2024

June 25, 2024  13 minute read  

I’ve been away from React development for a while. I stupidly asked what the best way to create a React app was in 2024 on the React subreddit, and found that reddit is not a friendly or welcoming community. For those wondering, there are three ways of creating a React app - Vite, Remix, and NextJS - but the community suggests Vite. Given the somewhat frosty reception I got on the React subreddit, I decided to do my own research across a number of topics for a new project - a social media c...

Build a Blog: Going to production with Azure Static Web Apps

June 08, 2024  4 minute read  

I’m almost ready to take my Static Web App to production and make it public. However, there are a few things that I want to make sure I do before going to production. This is true of any application hosted in the cloud, so it;s a good reminder of things to think about. This post is part of a sequence showing how to deploy a blog on Azure Static Web Apps: Deploying Azure Static Web Apps Configuring Azure DNS Configuring Static Web Apps Custom Domains Taking Static Web Apps to Pr...

Build a Blog: Custom domains for Azure Static Web Apps

June 07, 2024  8 minute read  

In my last post, I registered a DNS domain name and set up Azure DNS for it. I want my blog to use that domain name, so I need to set up a custom domain in Static Web Apps using Azure DNS. Of course, nothing is that simple. My blog uses repeatable deployments via Azure Developer CLI, so there is a little bit of extra work to do. This post is part of a sequence showing how to deploy a blog on Azure Static Web Apps: Deploying Azure Static Web Apps Configuring Azure DNS Configuring ...

Build a Blog: Set up DNS in Azure

June 06, 2024  4 minute read  

Today, I’m continuing on the job of setting up a new blog. I’ve now got three blog posts, so that’s enough for me to consider what I need to do for production. I don’t have a domain yet, so this post is all about setting up the domain. This post is part of a sequence showing how to deploy a blog on Azure Static Web Apps: Deploying Azure Static Web Apps Configuring Azure DNS Configuring Static Web Apps Custom Domains Taking Static Web Apps to Production Step 1: Pick a name Wh...

Build a Blog: Deploy Azure Infrastructure three ways

June 05, 2024  16 minute read  

For most developers, dealing with the infrastructure part of the job is hard. I like to say “give me a database and a web site” and prefer not to get into the other requirements like DNS, security, and multi-region reliability. My web sites and other cloud projects (including this one) are pretty open. So, what’s the minimum I need to know to deploy stuff on Azure? How can I get my project deployed on Azure for development with the minimum of hassle? This post is part of a sequence show...

Dev containers are a developers best friend

June 04, 2024  6 minute read  

If you’ve ever had to rebuild or significantly upgrade your machine in the middle of a project, then you will recognize the pain. You find that some versions of your favorite tools have changed, or you don’t remember the specific build command or tool download location for that one thing you rely on. Dev containers was designed with this in mind. It’s the technology behind Codespaces and supported in Visual Studio Code. In this tutorial, I’ll walk through the steps to create your own dev ...

Create an App Registration for RBAC with PowerShell and Microsoft Graph.

January 19, 2024  5 minute read  

I’m currently working on some automation within Azure to deploy a hub-spoke web application. This web application authenticates with Entra ID using an App Registration and Role-Based Access Controls (RBAS) using App Roles. So, I need to create an app registration, enterprise app, and create the app roles. Seems easy, right? Get an access token Since this is part of a deployment, I’m going to assume the user has already connected to Azure using Connect-AzAccount and selected a subscriptio...

Deleting Azure resources the right way.

July 12, 2023  3 minute read  

If you are an Azure developer, you likely spin up an application, do some work, then shut it down again. However, shutting down resources and deleting them has an order to them. If your service is network isolated (in a virtual network), then you can’t delete the application until the private endpoints are shut down. Budgets don’t get deleted with the resource group. Diagnostic settings can’t be deleted if the resource no longer exists. There is an order you should do things: Private...