Uncategorized

Is your enterprise Angular application accessible? — Better it’s, before June 2025.

Is your enterprise Angular application accessible? — Better it is, before June 2025. Open AI Dall-e-2 generated scene image If your enterprise application is not compliant with the Web Content Accessibility Guidelines (WCAG), your company might be sued with serious penalties that may reach 250k EUR, depending on the business and the country. In France, for example, the government …

Is your enterprise Angular application accessible? — Better it’s, before June 2025. Read More »

Ajustes automáticos en las imágenes optimizadas por Angular

Cómo la directiva NgOptimizedImage calibra las imágenes para ser representadas eficientemente En el ámbito del desarrollo web, optimizar las imágenes para una adecuada representación visual es crucial. Este artículo resalta los ajustes que efectúa la directiva NgOptimizedImage, esa característica del framework de Angular que permite de manera sencilla comunicar a los navegadores cuáles imágenes priorizar …

Ajustes automáticos en las imágenes optimizadas por Angular Read More »

Automatic Adjustments in Angular’s Optimized Images

How the NgOptimizedImage directive streamlines image rendering performance In the realm of web development, optimizing images for appropriate rendering is crucial. This article highlights the built-in performance adjustments offered by the NgOptimizedImage directive, a powerful feature within the Angular framework that seamlessly enables browsers to anticipate which images to prioritize or defer, assists in responsive …

Automatic Adjustments in Angular’s Optimized Images Read More »

How do I test Signals (signal, computed, effect)?

Signals as lightweight “reactive primitive” will shape the future of Angular applications. At the time of this writing, signal() and computed() are stable, and effect() is in developer preview. Developer preview doesn’t mean we have an unstable feature but that the Angular team can introduce breaking changes within a major version. The feature is stable; …

How do I test Signals (signal, computed, effect)? Read More »

How do I test using the RouterTestingHarness?

Historically, creating a test involving the routing context without mocking it has been challenging. This is mainly due to less-than-optimal documentation on RouterTestingModule or provideLocationMock. In the meantime, some community projects, especially Spectacular from Lars Nielsen, have helped us out. Spectacular by ngworkers | Spectacular This article explains how to use the RouterTestingHarness to write sound …

How do I test using the RouterTestingHarness? Read More »

How do I test code using inject()?

This article discusses testing Angular code, which uses the inject function for dependency injection. If you are more of a visual learner, here’s a video for you: https://medium.com/media/e1f4a05a89392e4ab835000ea9d9e832/href Why inject()? The inject function, introduced in Angular 14, is an alternative to the constructor-based dependency injection. inject has the following advantages: 1. Standardization of Decorators Decorators have …

How do I test code using inject()? Read More »

How do I test and mock Standalone Components?

If you prefer the kind of tests that minimize mocking as much as possible, you will be pretty happy with Standalone Components. Gone are the struggles of meticulously picking dependencies from NgModules for your Component under test. Standalone Components come self-contained. Add them to your TestingModule’s imports property, and all their “visual elements” — Components, Directives, Pipes, and …

How do I test and mock Standalone Components? Read More »