rest destructuring assignments are not safe for closure compiler because tsc/tsickle emits property names as quoted strings. It looks like it should be pretty simple to apply goog.reflect.objectProperty here
Example Input:
const input = {x: 1, y: 2, z: 3};
const {x, ...rest} = input;
Current Emit:
const input = { x: 1, y: 2, z: 3 };
const { x } = input, rest = __rest(input, ["x"]);
Proposed Emit:
const input = { x: 1, y: 2, z: 3 };
const { x } = input, rest = __rest(input, [goog.reflect.objectProperty("x", input)]);
Related: #241
This probably applies to other emit too
Reactions are currently unavailable
rest destructuring assignments are not safe for closure compiler because tsc/tsickle emits property names as quoted strings. It looks like it should be pretty simple to apply goog.reflect.objectProperty here
Example Input:
const input = {x: 1, y: 2, z: 3}; const {x, ...rest} = input;Current Emit:
const input = { x: 1, y: 2, z: 3 }; const { x } = input, rest = __rest(input, ["x"]);Proposed Emit:
const input = { x: 1, y: 2, z: 3 }; const { x } = input, rest = __rest(input, [goog.reflect.objectProperty("x", input)]);Related: #241
This probably applies to other emit too