linwenling
2023-08-13 e38f6d08af8b36f4c394257c5ebcdc4f111cde7e
1
2
3
4
export function removeFromArray(arr, elem) {
  const idx = arr.indexOf(elem)
  if (idx !== -1) arr.splice(idx, 1)
}