mirror of
https://github.com/angular/angular
synced 2026-05-24 09:28:37 +00:00
12 lines
341 B
TypeScript
12 lines
341 B
TypeScript
/**
|
|
* @license
|
|
* Copyright Google LLC All Rights Reserved.
|
|
*
|
|
* Use of this source code is governed by an MIT-style license that can be
|
|
* found in the LICENSE file at https://angular.dev/license
|
|
*/
|
|
|
|
export function removeListItem<T>(list: T[], el: T): void {
|
|
const index = list.indexOf(el);
|
|
if (index > -1) list.splice(index, 1);
|
|
}
|