if I have two objects:
{a: 1, b: {c: 1}}
and
{d: 1, b: {e: 2}}
Is there an easy way to merge the two nondestructively to create the following object?
{a: 1, d: 1, b: {c: 1, e: 2}}
if I have two objects:
{a: 1, b: {c: 1}}
and
{d: 1, b: {e: 2}}
Is there an easy way to merge the two nondestructively to create the following object?
{a: 1, d: 1, b: {c: 1, e: 2}}
Yes, you can use Lodash. Here's the link to the method you need: https://lodash.com/docs/4.17.10#merge