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
add support for external template/styles in webpack branch #1371
I tried removing the isMobile special case from app.component.ts and use the standard templateUrl and styleUrls to see if the new webpack magic would automatically fix the issues with loading external templates, but it still fails. I walked through with @gdi2290 and he proposes that we make the webpack app shell plugin (addon/ng2/utilities/prerender-webpack-plugin.ts) run against webpack-already-processed files/bundles, which will have already inlined the template and styles via the angular2-template-loader.
Patrick says he can have it done in 5 minutes from now.
Reacted by Michael Prentice, Morgan O'Neal, John Eckhart and Johannes Rudolph
Reacted by Anthony Ciccarello, Ben Shope and philippe beroucry
I got it working in 5 minutes but ran into a problem with importing in different contexts (known problem when working in Node with Angular 2 because Angular's di relies on references. The other problem is Reflect which has the same problem). I just need to isolate the prerendering in a separate process
I like that idea, it will make mobile much less special-case-y.
I should mention that at the moment we're using a built-in version of angular/universal#464 instead of importing prerender-webpack-plugin.ts, but that we should import it once the PR is in.
Activity
PatrickJS commentedon Jul 19, 2016
I got it working in 5 minutes but ran into a problem with importing in different contexts (known problem when working in Node with Angular 2 because Angular's di relies on references. The other problem is Reflect which has the same problem). I just need to isolate the prerendering in a separate process
filipesilva commentedon Jul 19, 2016
I like that idea, it will make mobile much less special-case-y.
I should mention that at the moment we're using a built-in version of angular/universal#464 instead of importing
prerender-webpack-plugin.ts, but that we should import it once the PR is in.PatrickJS commentedon Jul 19, 2016
it shouldn't be too hard to also prerender other pages with folders using the router config. I got it working if
routeswas exportedfilipesilva commentedon Jul 28, 2016
@gdi2290 did you manage to get it working? If you point me in the right direction I can maybe pick it up.
hansl commentedon Jan 11, 2017
Closing this as fixed already.
angular-automatic-lock-bot commentedon Sep 6, 2019
This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.
Read more about our automatic conversation locking policy.
This action has been performed automatically by a bot.