-
Notifications
You must be signed in to change notification settings - Fork 25.4k
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
App startup lag around linkDynamicModule #8724
Comments
Module loader performance in general is very disappointing if you throw the angular modular structure against it. I guess thats the reason why the bundles where removed in rc.0 At the moment the team experiments with http://rollupjs.org/. A module bundler that can get rid of the module syntax alltogether and removes unused methods in the process. @robwormald has a test repository https://github.com/robwormald/ng2-compiler-test2 that spawned from ng-conf. The build there is just 50kb gzipped and loads very fast. I hope he writes a blog about it or we get a rollup guide like the webpack one on https://angular.io/docs/ts/latest/guide/webpack.html |
Thats good information, I remember that talk well, the performance was fantastic. I use the CLI though so I'm not quite ready to change the build strategy just yet. |
the AOT compilation and squashing modules via rollup addresses this problem. CLI will have these features enabled by default in the future releases. In the meantime it's possible to set these up via your own build pipeline. |
@IgorMinar looks like it's in the current build |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Using RC0 and the AngularCLI I have generated a project and after working on it for a while I performed a prod build in the CLI and tested the deploy of the project. I noticed there is an almost 1 second delay from the point at which my
main.js
andindex.js
files are retrieved and my first component is pulled down.Here is my bootstrap.
bootstrap(WfaNg2AppComponent, [ ROUTER_PROVIDERS, provide(LocationStrategy, { useClass: HashLocationStrategy }) ]);
Here is the network tab during the bootstrap.
Here is the timeline for that period of wait.
If I turn off hash location strategy here is my network.
Here is the timeline with the hash location strategy off.
The text was updated successfully, but these errors were encountered: