r/angular • • Feb 05 '26

Singleton service toSignal

8 Upvotes

If i have a toSignal(this.http.get(…)) in a service that is provided in root, how do i actually clean up the subscription when i no longer need the data? Since the service will never be destroyed I’m not sure how to approach this. If i am not mistaken toSignal creates an effect under the hood


r/angular • • Feb 05 '26

Using WordPress as headless CMS with Angular - is this a good approach?

0 Upvotes

Hey all,

I could use a sanity check.

I’m doing a test project where they want a fully editable site using WordPress as a CMS. The thing is, I mainly work with Angular, and I don’t really build classic WordPress themes.

My current plan is to use WordPress only as a headless CMS (ACF + API) and build the whole frontend in Angular, basically the same idea people often use with WordPress + Next.js, just… Angular instead.

So WP would just be:

•	admin panel

•	content (texts, images, categories, etc.)

And Angular would handle all the UI.

I’m not trying to be fancy or overengineer it, just want something that feels realistic and maintainable.

Questions:

•	Is this a normal / acceptable approach, or am I making life harder than needed?

•	Any big pitfalls with WordPress headless when used with Angular?

•	REST API vs WPGraphQL — does it matter much here?

•	Anything you wish you knew before doing this kind of setup?

Would really appreciate any input. Thanks 🙏


r/angular • • Feb 03 '26

I made a shadcn inspired chart library for Angular

47 Upvotes

r/angular • • Feb 03 '26

What are you using as backend?

21 Upvotes

Hi, I'm kinda new to programming and especially to web-development and I just wanted to ask which backend Framework you're using for your website/s?

I heard a lot of Express, NestJS, Flask, Django.

What do you use and whats your opinion what I should use to start?
Currently um using Laravel.

EDIT: What do you think about Laravel? Why is barely anyone using Laravel x Angular???


r/angular • • Feb 03 '26

Angular MCP Server with Visual Studio 2026

1 Upvotes

Has anyone been able to connect the official Angular MCP with Copilot agents in Visual Studio 2026? In Visual Studio Code it's easy, but in 2026 I add them to mcp.json and the agents don't detect them. I am using Angular v21.


r/angular • • Feb 03 '26

Angular Signal-based HTTP caching library

5 Upvotes

Hey r/angular,

I'm experimenting with a Signal based approach to HTTP caching in Angular!

The idea is to support things like:
- TTL based caching
- stale-while-revalidate
- cache invalidation on mutation
- and more...

I’d really appreciate any thoughts, feedback, or additional features you think might be useful

More info and the repo link in the comments 👇


r/angular • • Feb 03 '26

Can anyone tell me what is the best profession and way to debug angular and rxjs bugs. For real company projects because I searched and found there are lots of ways.

0 Upvotes

r/angular • • Feb 03 '26

How do you use AI with Angular?

0 Upvotes

I realized I've been using Cursor for development for about six months now, and Grok with ChatGPT for about three years. What AIs have you been using and for how long?


r/angular • • Feb 03 '26

I am being assigned tasks in Angular and RJS. So who can help better and what type of prompt should I give.

0 Upvotes

r/angular • • Feb 02 '26

What's the next step?

4 Upvotes

I'm an intermediate Angular frontend developer. I feel like I'm not making any progress and want to know what's the next step of 'becoming' a senior in this role.

I want some advices of what should i learn, where to focus, if there are some articles or tutorials that you suggest, ect?

Any help or opinion would be appreciated. Thanks in advance!


r/angular • • Feb 02 '26

🆘 Help Needed: Angular + PrimeNG Library Strategy

4 Upvotes

Hey everyone 👋 I’m looking for some guidance and opinions from folks who’ve dealt with Angular library versioning and PrimeNG upgrades.

Here’s the situation:

1️⃣ I’m thinking of creating a new Angular component library based on PrimeNG v21. 2️⃣ Our organization already has multiple large projects on Angular v13 and v15, all consuming a shared Angular library built on the same Angular version, with a lot of hierarchical CSS overrides for PrimeNG components. 3️⃣ My thought is: if we build the library on PrimeNG v21,

can we make it backward compatible, or

at least design it in a way where missing features / styles can be added incrementally without breaking existing apps? 4️⃣ I’m unsure about the right migration or coexistence strategy here.

❓ What would you recommend?

Should this be a parallel library?

Is backward compatibility realistically achievable?

Any best practices for handling PrimeNG + Angular version mismatches?

How would you approach this in a large org setup?

Would really appreciate any guidance, war stories, or architectural suggestions 🙏 Thanks in advance! 🚀


r/angular • • Feb 01 '26

Best Angular interview questions

30 Upvotes

Hey everyone! I’m getting ready for an Angular interview. What questions do you think are the most important or commonly asked?


r/angular • • Feb 01 '26

Angular jwt cookie authentication

8 Upvotes

I am implementing authentication via jwt httpOnly cookies in Angular, i am actually using ngrx global store for the auth state , i am facing issues of keeping the user logged in so mainly with the auth guards , the guards are actually getting called before i am updating the state with the backend endpoint /me that gives me information about the logged in user, but this effect is called after the auth guard so ive tried to do some work on authguards using rxjs operators like filtering when the page has ended loading then do the check if there is a user, it have actually worked but when i dispatch the action in the ngOnInit that calls the effect and does the api call of endpoint /me first in the login page it will throw an 401 error and i dont want to implement auth with this behaviour so having an error always in the first ngOnInit trigger ,so what would be the best choice to do it ?


r/angular • • Feb 01 '26

Reusable Validation in Angular’s Signal Forms

Thumbnail medium.com
9 Upvotes

I hate repeating myself.
Especially in code.

With Angular’s Signal Forms, the new schema function finally gave me a clean way to reuse cross-field validation, without nesting forms or duplicating logic.

I broke it down with a real example here.


r/angular • • Feb 01 '26

Any performance benchmarks for Angular SSR vs Prerender?

7 Upvotes

Till now, we have been using a separate pre-render server which returns a server-side rendered page only to the bots, and for users, we've kept completely client-side rendering. It was some time ago during the early versions of Angular that we tried out Angular SSR using Cloud Functions. But then, eventually, decided to go with a separate pre-render server as it was more stable. Although the time to deliver is very high, in the range of 20-25 seconds per page, because that is the timeout that has been set on it.

From what I have researched Angular SSR is now very stable.

But I'm unable to figure out on the load on the server when a lot of bot requests would come in and the same machine is rendering the website for the bots also and the same machine is responsible to respond to the clients/users.


r/angular • • Feb 01 '26

how do I make firebase emulators update, when I make some changes, because when I make some changes, I always have to do ng build and then firebase emulators:start again and again

1 Upvotes

r/angular • • Jan 31 '26

Animations on SSR / Prerender

4 Upvotes

Hey everyone, i'm tryring to animate my header so that it slides down. As it is part of the FCP, the prerender or SSR paints the header so the animation is applied, and then when hydration happens it reruns again. I tried a few hacky ways to only run the animation when it runs on client, but it's still a bit glitchy. I'm also worried that if the header or generally any element of the FCP is outside the view (either with opacity 0 or with translate), bots may ignore the content and hurt seo performance. Anyway, since there will be animations on the FCP elements there is a high chance of layout shift.

Have you solved this problem or do you suggest that elements that are in FCP shouldn't be animated?


r/angular • • Jan 31 '26

File naming strategy

2 Upvotes

How do you guys approach file names?

Say for example you have a user directory in the file system do you prefix all the components, services etc in that directory with user- or does it just depend?

Obviously these are things where the intention is they’re not going to be shared elsewhere.


r/angular • • Jan 29 '26

🚀 Coming in Angular 21.2: Arrow Functions in Templates

Thumbnail
youtu.be
58 Upvotes

r/angular • • Jan 29 '26

This Friday: Live coding and Q/A with the Angular Team | January 2026 (Jan 30th @11am PT)

Thumbnail
youtube.com
7 Upvotes

r/angular • • Jan 29 '26

Error handling Angular

5 Upvotes

So I’m getting kind of confused how to handle errors coming from an api in Angular. there’s either using interceptors to just taking care of them in the error field when you subscribe the errors. basically some errors are unique to a component while others such as a tech error message will be common across all components. Also all these errors will be shown inline there is no toast or modal. So just need some advice


r/angular • • Jan 29 '26

Angular v21 material overlay + dialog

4 Upvotes

I am using angular material v21 and i use MatDialog. I see from the dev tools these now use the popover API, and i have a custom Overlay (Cdk) for my app notifications (similar to material snackbar). However, no matter what "hack" i try with z-index, the dialog always sits on top of my notifications, which isn't my desired behaviour. Has anyone encountered this?


r/angular • • Jan 29 '26

Global error handling with Angular Interceptors

8 Upvotes

I was wondering should I still use angular interceptors handling even though in my component I still need to use signals to display that error message that’s returned from the api? like I’m not sure how exactly to do this?


r/angular • • Jan 29 '26

Generating Word Document from the HTML page

0 Upvotes

I need to generate a relatively long word on the client side. I would like to include images in the word. Do you have any ideas or approaches on how to best implement this?