-
Notifications
You must be signed in to change notification settings - Fork 69
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
Is this project active? #41
Comments
Hi yes this project is actively used in different places however the angular AOT plugin and @ngtools ships with its own template inlining feature. When I first created this project, I was not a maintainer of the webpack org. Since joining the webpack core team, this repo has been neglected a bit but I am open to PRs and features. |
I'm not up-to-date with angular-cli and @ngtools, so here I'm asking: what would be the alternative path to not use this loader anymore? Of course, still remaining with angular 2, webpack 2, typescript 2, ... Thanks |
angular2-template-loader is great for JiT builds along with awesome-typescript-loader, also great for testing, but JiT builds are no longer acceptable production solutions given their longer than reasonable render times. For AoT, @ngtools/webpack is used in place of the combination of awesome-typescript-loader and angular2-template-loader, and the AoTPlugin (shipped within @ngtools/webpack) takes care of your ngc compilation (ngc is a wrapper around tsc that a) transpiles your typescript, and b) does the Ahead-Of-Time compilation that is the namesake of AoT). For example, here's my loader configuration for JiT builds and AoT builds:
And my plugin configuration for the AoTPlugin:
|
Should be noted though that apparently @ngtools/webpack can also handle JiT builds, I'm just used to this particular toolchain and it's been good to me. :) Much respect, @TheLarkInn. |
Hi @nikolasleblanc and thanks for your info! My bad for not being clear: @TheLarkInn is doing a great job, was just asking him what is he suggesting, given the current "work overload" and progress in angular-cli . Also (my bad again), I'm aware of JIT Vs AOT, and before some recent issues I had with awesome-typescript-loader and some I'm now having with angular2-template-loader, my team was happy bundling both a dev JIT build as well as an AOT production build, the latter also with angular-router-loader and lazy-loading (also waiting on next angular 4 to see some more improvements on tree shaking). Now, it's a couple of days that we're stuck with these weird issues, in particular #50 and other similar listed here. Back to your experience, if I got it right: angular-cli and/or @ngtools/webpack can take the place of awesome-typescript-loader + angular2-template-loader, both for JIT and AOT builds. Q1: Is that right? Thanks for your help |
Yup. Just, personally, I stick to angular2-template-loader and awesome-typescript-loader for my JiT stuff, which is really just for e2e and testing since they compile faster.
Pretty sure you can bring in angular-router-loader as part of your JiT build, and @ngtools/webpack handles lazy loaded routes for you when building AoT. See https://www.npmjs.com/package/@ngtools/webpack#features.
Re your issue #50, I commented there. |
Oh and I wasn't suggesting you were giving the LarkInn any grief, I just felt it was time for me to give him some props. :) |
Seeing that the last active issue is from late September.
The text was updated successfully, but these errors were encountered: