I've the following code:
arr = [];
var item={
id: '2',
step: 'step2',
label: 'Banana',
price: '19$'
}
arr.push(item);
How can I check if this particular item exists in JS. For example, how can I check that id = 2
exists ?
And how can I remove it from the array if found ?
Thanks.