You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In 0e33806 I noticed that, at the current point, at least static fields must have a type annotation because these are compiled lazily but might become resolved before being compiled, and there isn't a proper resolveExpression for any expression yet that we could use if there wasn't a type annotation. Hence, implementing a full-fledged resolver seems to be one requirement to make this proposal work without exceptions.
dcodeIO
changed the title
[Feature] Allow infering for default init fields & params
Support type inference on function parameters and class fields
May 27, 2020
It's probably possible to do this using TypeScript's compiler API.
It might also be possible to do this using Hegel, though it only works with a statically-typed subset of JavaScript.
The text was updated successfully, but these errors were encountered: