Advertisement
deddyprianto

remove item from array object

Jan 16th, 2024
28
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.13 KB | None | 0 0
  1. const removeItem = [...cartInfo.details];
  2. removeItem.pop();
  3. dispatch(setCartInfo({ ...cartInfo, details: removeItem }));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement