I want to convert one array to another kind of array. Actually I am using typescript. What am I doing wrong here:
//terminals is an array of objects.
groupOptions = terminals.map(trm => {
id: trm.TerminalID,
text: trm.TerminalName,
selected: true
});
intelisence complains about the body of the curly brackets. With them I meant an object, probably intellisence thinks its anonymous method body. How can I workaround this?