Questions tagged [angular10]

Questions about Angular version 10, the web framework from Google. Use this tag for Angular questions which are specific to only version 10. Use tag Angular for any Angular questions which are not specific to an individual version

Breaking Changes:

  • Typescript 3.6, 3.7, and 3.8 are no longer supported. update to Typescript 3.9.
  • Input fields of type number fire the valueChanges event only once per value change (as opposed to twice in some cases). See PR 36087.
  • The minLength and maxLength validators only validate values that have a numeric length property. See PR 36157.
  • Templates with unknown property bindings or unknown element names now log errors instead of warnings. See PR 36399.
  • UrlMatcher can now return null values. See PR 36402.
  • Transplanted views now refresh at insertion point only. See PR 35968.
  • Formatting times with the b or B format codes now supports time periods that cross midnight. See PR 36611.
  • Navigation is canceled for routes with at least one empty resolver. See PR 24621.

See the changelog for latest version information.

Read more at the Angular Website

837 questions
0
votes
1 answer

Angular update parent data from child component

Yes, this old chestnut. I'm making an editor for a large object tree, and it seemed sensible to make components for each of the property types at a vertex in the tree in order to remove clutter from the main component. However, this has created the…
Richard Barraclough
  • 2,625
  • 3
  • 36
  • 54
0
votes
1 answer

Angular 10 - Change Order of Execution in AfterViewInit When Using Subscription

I have this ngAfterViewInit lifecycle hook: ngAfterViewInit() { this.sort.sortChange.subscribe(() => this.paginator.pageIndex = 0); this.subscription = this.dataService.dataChanged .subscribe( () => { …
0
votes
1 answer

Fails to find library aliases in unit tests after upgrading to Angular 10

After upgrading to Angular 10, I am having issues running the libraries' unit tests. I have two project libraries. For example LibTest1 HeroTest2 HeroTest2 consumes LibTest1 Project tsconfig.json contains { ....... "baseUrl": "./", …
0
votes
1 answer

Filter items in ng-for by search and show categories for those with results

I have created an app to display elements from JSON. I have 1500+ items in a big array, as well as in an array of arrays containing the items sorted by categories. const fullDataSet = [{name: 'Foo', category: 'vegetable'}, {name: 'Bar', category:…
DuGabiche
  • 93
  • 2
  • 8
0
votes
1 answer

How to display different components recursive?

I have a app-document-form-node component that recursive builds components. Component app-document-form-node:
user13821408
0
votes
1 answer

Angular CLI 10 ng build --prod emits empty lines

When building angular app using CLI if we use ng build --prod it will emit 2 empty lines, and if I remove --prod , these empty lines are gone. On my dev environment, it's very minor but when I am trying to build app via TFS these empty lines…
Posto
  • 7,362
  • 7
  • 44
  • 61
0
votes
1 answer

Use susielu/d3-annotation into Angular 10 Application

I'm trying to import and use susielu/d3-annotation into an angular project. "@types/d3": "^5.7.2", "d3": "5.15.0", "d3-svg-annotation": "^2.5.1", That is part of my package.json Inside a component, I'm able to use d3 with the following…
Zeno Trevisan
  • 517
  • 1
  • 8
  • 23
0
votes
1 answer

Duplicate ID generation in ngForOf - Angular

I am using ngForOf to list dates, each date is represented by id property which is actually its index + 1. All the dates are present in form of object in an array. Also, each date is a component instance. The thing with ngForOf is that whenever I…
Hasham Ali
  • 33
  • 1
  • 7
0
votes
2 answers

On Click event the textarea field should be empty

I am a very new user of Angualr and currently using Angular 10. I want the textarea field that should be empty after click on the clear button. But this code is not working that I want to do. Could someboday help me. Thanks. HTM file
Atika.Akmal
  • 11
  • 1
  • 3
0
votes
1 answer

ionic 5 - routing to details page with page id issue

guys , I am creating and ionic app which has details page with page id, I am trying to configure router, its not redirecting its always on main page , my code is below please check ? parent page route import { NgModule } from…
0
votes
1 answer

Angular undefined value of @input variable

I'm new to Angular and I have some issues , hope you'll help me. so I'm trying to share a value of a variable from a ProjectComponent to an AcceuilComponent , the value of this variable is displaying correctly into my acceuil.component.html but when…
heyhi
  • 33
  • 1
  • 6
0
votes
1 answer

Why is the mat-autocomplete not displaying the searched options?

This is the form that I am using:
Panda
  • 499
  • 11
  • 22
0
votes
1 answer

Find parent form control when it's in a FormArray

In a child component I need to get a FormControl from a parent's FormGroup. It's easy enough to do by injecting FormGroupDirective into the constructor and then calling .control.get() on that injected item. However, if the form control is actually…
Gargoyle
  • 9,590
  • 16
  • 80
  • 145
0
votes
1 answer

Extra character is gettting added in API URL in angular

Environment file export const environment = { production: false, name: 'local', apiUrl: 'https://dev.xyz.com/v1', }; API service login(input: ILogin): Observable { Common.showConsoleLog('demoAPIReq', input); const url1 =…
0
votes
0 answers

How to bind and emit dynamic events in dynamic component in angular

I am following this excellent article to create dynamic components in angular and it works properly. Its passing an array of elements to be rendered dynamically in below format. config.push( { type: 'select', label: 'Month', …
Sunil Chaudhary
  • 397
  • 1
  • 9
  • 31