Open gc1508 opened 5 years ago
In my use case, I am dealing with two array that I need to combine into one single array according to some conditional logics:
let input = { required: [ "name" ], properties: [ { id: "name" } ] }
let expected = { properties: [ { id: "name", required: true } ] }
How can I implement mapping logics that allow me to compare the two arrays, required vs properties?
THanks!
In my use case, I am dealing with two array that I need to combine into one single array according to some conditional logics:
let input = { required: [ "name" ], properties: [ { id: "name" } ] }
let expected = { properties: [ { id: "name", required: true } ] }
How can I implement mapping logics that allow me to compare the two arrays, required vs properties?
THanks!