Expression has changed after it was checked during iteration by map keys in angular 2

Don’t bind to a method ...keys() in the template.
It will be called every time change detection runs.
object.keys() returns a new object every time it is called and Angular recognizes this as an unexpected change, which leads to your error.

You can fix it like

someMethod() {
  this.bindedAuthorsKeys = this.bindedAuthors.keys();
}
*ngFor="let author of bindedAuthorsKeys"

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)