I am trying to copy an object, but I only want certain properties from the source object i.e. none of the read-only properties. I have tried let a = b, const b = Object.assign({}, a) etc.
Source Object is an array with the following properties: -
0:
accountId
customerId:
description:
image:
items: (4) [{…}, {…}, {…}, {…}]
productTitle:
selected:false
$exists:
$key:
__proto:
I only want the following properties in the new object:
0:
items: (4) [{…}, {…}, {…}, {…}]
productTitle:
Can anyone advise on the best way to do this?