Category "angular"

Angular Web Component routing reroutes to last component routed when we get back to the web component

We have built a web component with angular elements and consumed in a parent angular application. But the problem seems to be with the web component routing. It

using Moment with Angular library 13 causes an error

When i use the moment.js (latest version) in an angular library, i am facing the following problem: vendor.js:sourcemap:106713 ERROR TypeError: (moment__WEBPACK

RXJS data manipulation

I am trying to find the reactive way of manipulating data in an array of objects. In the array below, I want to determine the low score in groups of four and a

Rxjs only execute last item in queue with concatMap

I am using NGRX with RXJS. In the effects layer, I am using a concatMap to queue my requests, however, once the latest request is complete, I want to execute th

mat-datepicker change date format not working

I am using the providers in my module to change the format of the datepicker in FiltriRecuperoComponent see code below export const MY_FORMATS = { parse: {

Incorrect functioning of routes in Angular

When trying to navigate from 'users' to 'users/:id' like this this.router.navigate([`/users/${userId}`]); or this.router.navigate(['/users', userId]); it stay

how to grab the payload inside of withlatestfrom with ngrx?

hi i have the following code where the selector requires an index to grab a value from the store, I use withLatestFrom to grab this value from the store only th

Installing dependency produces: ERESOLVE unable to resolve dependency tree

When I try to install a dependency I get the following error. How can I fix this? npm ERR! code ERESOLVE npm ERR! ERESOLVE unable to resolve dependency tree npm

call javascript void in angular

I am using an html template for a website in Angular This template uses JavaScript to perform page elements. My problem is that when I use ngfor to create an el

window.removeEventListener not working in Angular

I can't for the life of me find out, why the eventlistener isn't removed on the mouseup event. I have already tried a lot of different things, but I can't remov

Angular Ag-Grid row group empty render when querying DOM elements with angular-testing-library

I have an ag-grid that contains different columns and column groups, as well as row groups. I am trying to test the DOM elements displayed in the row group usin

@Injectable giving undefined in angular 13

Hello guys I've recently updated angular to the version 13 and I'm experiencing some issues regarding DI. When I call the ReflectiveInjector.resolveAndCreate()

How to return Observable from Callback

I have a service in which I want to implement the logic of an SDK. From this SDK I want to call an event that returns a payload. I want to create a method in wh

Angular not passing object to html page

I am having issues with learning angular, I didn't use to have these problems before, but now when I do these demos things work great until I switch from using

Angular - Async pipe in ngIf and text binding will not display first emitted value

I have very simple component template: <button (click)="emitNextValue()">Next Value</button> <p *ngIf="text$ | async"> {{ text$ | async }}

How to test an Angular method which calls service and gets values?

I am trying to test this method, I have tried spying but the coverage shows not covered. Basically what this method does is, it checks if there is data availabl

How to disable scroll on body when clicking on a p-dropdown within it

I am using few p-dropdown in my table header where I also have a horizontal scroll for it's container. When I click on any of these dropdowns, instead of openin

send "&" in url angular

I'm using the Angular version 12 I want to send the following object in query params: { dynamicQueryOperators: 6&dynamicQueryOperators=8 } But in the end

webpack-dev-server Disconnect and Trying to reconnect... spam

I just finished an angular project I was working on, but i noticed something in the console, which I'd love to hide if that's possible just to keep everything t

optional chaining in Angular Template

Compiled with problems:X ERROR src/app/components/users/users.component.html:2:22 - error TS2532: Object is possibly 'undefined'. 2 <ul *ngIf="loaded &