I have an object like obj = { test1: 'sth', test2: 'sth', label: 'sth' }
.
And I would like to destructure this object {...obj}
except label
to get { test1: 'sth', test2: 'sth' }
.
How to destructure the object without this key?
Should I create a new object or is there any way to do this simply in one line?