Gabe Moothart
Results
2
comments of
Gabe Moothart
But this is a very restricted case, we only promote field initializers if the assignment is to a literal: https://github.com/angular/clutz/blob/52f0713977411a64e4fdedb71bd4e5e82d5c3bdb/src/main/java/com/google/javascript/gents/TypeConversionPass.java#L423 It seems like it shouldn't be that hard to construct...
One option is to just omit the type annotation entirely and fall back on TypeScript inference. i.e. `private n = 5;` instead of today's `private n: any = 5;`