-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using fullTemplateTypeCheck
flag in the typescript angularCompilerOptions
raise an error
#150
Comments
This is actually a duplicate of #148 and Andrew was kind enough to create a PR for the fix which I'll fold in. That said, this is useful because it explains why I missed it...I didn't know about the fullTemplateTypeCheck flag and I did NOT turn it on. I'll make sure to add that to the AOT compilation so that these issues are preemptively caught going forward. Thanks! |
Oh I didn't see this one my bad. You are welcome. |
No problem at all and again, thanks for pointing out the flag. This will get folded into a release today. |
@maxailloud could you give me a very specific example of exactly how to generate the compiler warnings? I've spun up new angular-cli projects running against 1.7.1 and 1.7.3 and I can't seem to generate the warning. Thanks! |
I am using https://www.npmjs.com/package/ngm-cli to build an external module for my applications, basically it's a wrapper for Adding the compiler options in my tsconfig.json raised the error:
I am obviously using the angular-toaster module in one of the few modules in my package. |
Completely understandable and this is very helpful, thank you!! What mode is ngc running in for your project or are you not passing any sort of flag to ngc? |
The only thiing I can tell you is that the command |
I still can't reproduce this issue with those flags and angular-cli. I'm going to build a sample with ngm-cli and see if I can create a reproduceable example. I want the example so that I can catch this sort of thing during development going forward. Thanks for the information! |
Yeah I think angular-cli and ngm-cli have some difference even though they should both using ngc as compiler. But after angular-cli uses webpack too I think to build, correct me if i'm wrong, the difference might be from that. |
- Typescript compilation was failing for implicit any conversions for object typings for the configuration of showCloseButton, timeout, iconClasses and typeClasses. The type arguments have been strengthened to make more rigid compilation happy. This should not affect anyone who was not abusing the expected typed arguments. Closes #150, closes #148. - The webpack demo has been rebuilt against `angular2-toaster@5.0.0` and webpack 4. Closes #147.
I was updating the
angularCompilerOptions
in mytsconfig.json
file for an external module I am developing and here is the error I got when I turned on thefullTemplateTypeCheck
:I guess the compiler doesn't like the use of the
any
type at line 86 and 87 of the toaster-container.component.I am saying that because in the AoT documentation of Angular for this option it's written
So maybe it might be a good idea to see to fix this.
The text was updated successfully, but these errors were encountered: