Frontend

Articles about Frontend on omid.dev — guides, topics, and notes from the field.

The Hidden Cost of Nice Syntax: When Angular's New Template Features Make Code Harder to Reason About

Published: May 26, 2026 Reading Time: 5 min

Every framework eventually discovers the same truth: developers love nice syntax until nice syntax becomes a hiding place. Angular’s recent template improvements are genuinely useful. Multiple consecutive @case blocks make some @switch statements cleaner. Spread and rest support in templates removes awkward helper code in small cases. Angular 21.2’s template additions, such as arrow functions and exhaustive @switch checks with @default never, continue the same direction: templates are becoming more expressive and more type-aware. ...

Continue Reading

Signal Forms Aren't Just a Forms API Update: They Change How You Model UI State

Published: May 25, 2026 Reading Time: 6 min

Most forms discussions start in the wrong place. They compare syntax. Reactive Forms gives us FormGroup, FormControl, validators, status flags, and a lot of well-known muscle memory. Signal Forms gives us fields, signal-shaped state, form-level submission, custom controls, and migration tools. It is tempting to treat this as a cleaner API for the same old job. But that misses the bigger shift. Signal Forms are not only about filling inputs and showing validation messages. They push forms into the same mental model as the rest of modern Angular state: explicit signals, derived values, and state transitions that can be composed instead of chased through subscriptions. ...

Continue Reading

ViewChild Angular: Complete Guide to @ViewChild and @ContentChild

Published: September 8, 2024 Reading Time: 6 min

Angular’s @ViewChild and @ContentChild decorators provide a powerful way to interact with child components, DOM elements, and projected content within a component’s template. While they are often misunderstood or used interchangeably, each has its own specific purpose and use cases. In this comprehensive guide, we’ll dive deep into both decorators, understanding their differences, use cases, and best practices. Additionally, we’ll explore advanced techniques for leveraging them in various scenarios and edge cases, complete with sample code for hands-on understanding. ...

Continue Reading

Migrating from REST to GraphQL: A Step-by-Step Guide for Express.js and Angular

Published: August 7, 2024 Reading Time: 6 min

In today’s rapidly evolving web development landscape, GraphQL has emerged as a powerful alternative to traditional REST APIs. This blog post will guide you through the process of migrating your Express.js backend and Angular frontend from REST to GraphQL, unlocking the benefits of a more flexible and efficient API architecture. Companion resource Companion Project Explore the complete working example on GitHub. github.com/omidfarhang/example-projects/examples/graphql-express-angular-migration View on GitHub 1. Introduction REST (Representational State Transfer) has been the go-to architectural style for building web APIs for many years. However, GraphQL, developed by Facebook, offers several advantages: ...

Continue Reading

Creating Dynamic Music Visualizations with Angular and the Web Audio API

Published: July 13, 2024 Reading Time: 11 min

Music visualization has always been a fascinating way to enhance the auditory experience, offering a visual representation of sound that can be both mesmerizing and informative. With the power of modern web technologies like Angular and the Web Audio API, creating dynamic music visualizations is more accessible than ever. This blog post will guide you through the process of building an engaging music visualization application using Angular and the Web Audio API. ...

Continue Reading

Avoiding Framework Lock-in: A Frontend Team Leader's Guide

Published: July 4, 2024 Reading Time: 8 min

As a frontend team leader, one of your most crucial responsibilities is ensuring your team remains adaptable and forward-thinking in an ever-evolving technological landscape. While standardizing on a single framework can provide short-term efficiency, it risks limiting your team’s growth and flexibility in the long run. Let’s explore strategies to avoid this pitfall, complete with real-world examples. Focus on Core Principles At the heart of frontend development lie the fundamental web technologies: HTML, CSS, and JavaScript. These form the bedrock upon which all frameworks are built. By emphasizing mastery of these core technologies, you equip your team with transferable skills that transcend any single framework. ...

Continue Reading

Chaos Engineering for Frontend Applications

Published: July 1, 2024 Reading Time: 16 min

Frontend code runs on hardware and networks you never see. A user in rural Indonesia on a three-year-old Android phone over a flaky 3G connection experiences your application differently from a developer on fiber in Berlin. That gap is exactly where client-side chaos engineering pays off. This guide covers browser-side failure domains, resilience patterns, MSW and Cypress walkthroughs, real-time and auth chaos, SSR/hydration faults, performance pressure, offline sync, and tooling. For the shared experiment loop, blast-radius controls, and game-day concepts, start with Chaos Engineering: Principles and Practice. For fault injection on pods, networks, and datastores, see Chaos Engineering for Backend and Infrastructure. ...

Continue Reading

OpenTelemetry in Angular: Distributed Tracing Setup Guide

Published: June 28, 2024 Reading Time: 6 min

In today’s complex microservices architectures, understanding the flow of requests and pinpointing performance bottlenecks can be challenging. This is where distributed tracing comes into play, and OpenTelemetry provides a powerful toolkit for implementing it. In this post, we’ll explore how to build a distributed tracing system for Angular applications using OpenTelemetry, with a focus on microservices architecture and performance monitoring. What is a Distributed Tracing System? A distributed tracing system is a method of tracking and analyzing requests as they flow through various services in a distributed system. It provides a holistic view of how a request propagates through different components, helping developers identify bottlenecks, troubleshoot issues, and optimize performance. ...

Continue Reading

Implementing Custom Web Components in Angular with Stencil.js

Published: June 26, 2024 Reading Time: 6 min

In modern web development, the ability to create reusable components that work across different frameworks and libraries is crucial. This is where Web Components come into play. Web Components allow developers to create custom, reusable HTML elements with encapsulated functionality and styling. However, building Web Components from scratch can be complex and time-consuming. Enter Stencil.js, a powerful tool that simplifies the creation of Web Components. Companion resource Companion Project Try the working example in your browser or inspect the full source code behind this article. github.com/omidfarhang/example-projects/examples/angular-stencil-web-components Open live demo View on GitHub In this guide, we’ll explore how to create custom Web Components using Stencil.js and seamlessly integrate them into Angular applications. Whether you’re an experienced developer or just getting started, this comprehensive guide will walk you through each step of the process. ...

Continue Reading

Building a Decentralized Application (DApp) with Angular and Ethereum

Published: June 25, 2024 Reading Time: 6 min

In recent years, decentralized applications (DApps) have emerged as a groundbreaking paradigm in the world of software development. Unlike traditional applications that run on centralized servers, DApps operate on blockchain technology, which offers enhanced security, transparency, and decentralization. This guide will walk you through the process of creating a DApp using Angular and Ethereum, including smart contract development with Solidity. What is a Decentralized Application (DApp)? A DApp is an application that runs on a decentralized network, typically a blockchain. Unlike conventional applications, DApps leverage the decentralized nature of blockchain to provide a higher level of security and trust. Key features of DApps include: ...

Continue Reading