I\'d like to access typed object with bracket notation like this:
interface IFoo {
bar: string[];
}
var obj: IFoo = { bar: [\"a\", \"b\"] }
var name = \
I added it as a separate interface because i need to keep original..
export interface IIndexable {
[key: string]: any;
}
and referencing it when needed
getEditDate(r: IRestriction, fieldName: string) {
...
value={(r as IIndexable)[fieldName] as Date}
works well. i will update if i find a way to shorten it