Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
var state1 = {
val1 : 'abc',
val2: 'xyz'
};
var state2 = {
val2 : 'mno',
val3: 'xyz'
};
var state3 = { ...state1, ...state2}; //{val1: 'abc', val2: 'mno', val3: 'xyz'}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.