I am attempting to retrieve the value feature_1
associated with the key name
from the array data
. I then aim to set feature_1
as the key of another array asset
, with an array as its corresponding value.
For example:
//input:
data: {
name: "feature_1",
value_a: 1,
value_b: 2
}
//Output:
asset: {
feature_1:[1,2]
}