SATURN  RING  STATION

At a distant space view post, we chat about codes.

Array filter arrow function in Typescript

onEmployeeDelete(employee: Employee): void {
   
    ...

    this.employeesFullList = this.employeesFullList.filter(emp => emp.id !== employee.id);
}

This instead of finding index first then splice with it. WOHO!

Leave a Comment

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Array filter arrow function in Typescript