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
{{ message }}
Repository navigation
Regression: decorator must be on first of the defined property methods #12554
In 2.0.10, a decorator such as the Angular @Input decorator could appear on the second of the two methods implementing a defined property. As of 2.1.1, you get an error unless it appears on the first.
Expected behavior:
The code should work as it does when transpiled with 2.0.10
To see that changing the TypeScript version controls the outcome,
open config.js and toggle the TypeScript version to 2.0.10 to see that the code works fine when the decorator is on the second property method.
I compared the generated JS under TS 2.0.10 and 2.1.1.
The latter, failing version is missing the following important code:
This explains why the Angular app fails: Angular can't find that decorator and therefore proclaims that the CustomComponent does not have a bindable selectedSection property.
Activity
mhegazy commentedon Dec 12, 2016
Ron Buckton (@rbuckton) can you take a look.
rbuckton commentedon Apr 25, 2017
This was fixed for 2.1.5 via #12740, and is still working as of 2.3.0.