Posts

Building an Employee CRUD Application with React and TanStack Query

Image
Introduction Managing server state in a React application can quickly become complex. You need to handle loading indicators, error states, caching, background refetching, and cache invalidation after mutations. TanStack Query (formerly React Query) solves all of these problems with a declarative, hook-based API. In this article, we will walk through a complete Employee CRUD application that demonstrates how to: Read a list of employees and individual employee details using useQuery . Create a new employee using useMutation and navigate to the new record. Update an existing employee and refresh the cache automatically. Delete an employee and remove it from the cache. The project is built with React 19 , TypeScript , Vite , React Router v7 , React Hook Form , and Zod for schema validation. Application Architecture The diagram below illustrates how TanStack Query sits between the React UI and the backend APIs. Read operations flow through useQuer...

Building an Azure Application Insights Dashboard with ASP.NET Core 8 API & React 18

Image
Building an Azure Application Insights Dashboard with  ASP.NET Core 8 API  &  React 18 This article provides a complete hands-on guide with full source code for every file  building a monitoring dashboard that queries Azure Application Insights using KQL, secured with Microsoft Entra ID. ASP.NET Core 8 React 18 + TypeScript Azure Application Insights KQL Entra ID Auth TanStack Query Recharts Table of Contents Introduction What is Azure Application Insights? Features In-Depth Architecture & Execution Workflow Diagram Project Structure, Prerequisites & Packages Key Azure SDK Classes Explained (LogsQueryClient, MetricsQueryClient, Serilog) NuGet Packages Explained (Azure.Identity, Azure.Monitor.Query, Serilog) NPM Packages Explained (@azure/msal-browser, @azure/msal-react) API: Configuration (appsettings.json, AzureSettings.cs, EntraIdSettings.cs) API: Program.cs API: Models (LogEntry.cs, MetricModels.cs, KqlModels.cs) API: Service Int...