This repository has been archived by the owner on Dec 20, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 48
ngseed doesn't do lazy loading of controllers? #37
Comments
@mpiasta-ca First of all, thank you.
But I'm looking at |
Great, I think that will make this git repo one of the most popular angular seeds. Couple more suggestions I can make:
|
I'll create Trello cards from your input to make sure that it won't get lost |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Finally got
ngseed
setup after hours of error handling. Once I was able to take a look at how it functions in a browser, I was disappointed that all the *.js files (controllers, services, etc) are concat into a singlemain.js
file. Seems like the only files loaded dynamically/on demand are views, if I'm not mistaken?This isn't the best solution for mobile web apps, because it forces the user to download the [almost] entire site on the first page load. This can take a really long time with a choppy mobile data connection. So time-to-first is too consuming.
As well, a large app can easily send the initial page load to over 1MB, which is a big download for mobile. An app I'm developing right now needs to have ~10 different sections, and it would be regular for a user to enter 3-4 sections before exiting. So that means there is a lot of code being loaded that is never used. As a mobile web app, we want to go as easy on the customer's mobile data plan as possible.
I came across a solution called AngularAMD, and that concept does use lazy loading for controllers and views. I was hoping that the
ngseed
was based around that concept, becausengseed
had all the starting tools I was looking for -- including Gulp, Bower, routing, and sticking to the 'best practices for angular app structure'.Maybe you can expand your project to include AngularAMD? Or why is it that your team chose to concat the module *.js into a single file, was there specific goals with doing that?
The text was updated successfully, but these errors were encountered: