Tan Li Hau b6486a22cb fix destructuring rest with template literal (#10013)
* fix destructuring rest with template literal

* update test
2019-05-24 00:03:27 +02:00

11 lines
186 B
JavaScript

const input = {};
const {
given_name: givenName,
'last_name': lastName,
[`country`]: country,
[prefix + 'state']: state,
[`${prefix}consents`]: consents,
...rest
} = input;