9 lines
260 B
TypeScript
9 lines
260 B
TypeScript
//// [parserShorthandPropertyAssignment1.ts]
|
|
function foo(obj: { name?: string; id: number }) { }
|
|
var name:any, id: any;
|
|
foo({ name?, id? });
|
|
|
|
//// [parserShorthandPropertyAssignment1.js]
|
|
function foo(obj) { }
|
|
var name, id;
|
|
foo({ name: name, id: id });
|