0

I have run into an strange issue recently while using requirejs and AngularAMD for asynchronously loading modules. The site is loading perfectly but there is a blank white page for about 5 seconds(random time as i have too many dependencies) until all the dependencies are loaded by requirejs.

The browser pre-loader is also hidden and blank page is displayed, and after about 5 seconds, whoosh all content is visible.

icanbeacoder
  • 1,388
  • 1
  • 13
  • 30
  • Does all these dependencies need to load before the first partial can be inserted? Can't help you unless you share the code to reproduce the issue... – T J Apr 13 '16 at 13:34
  • @TJ, it's a simple angularAMD app, have followed this example: https://bl.ocks.org/marcoslin/df4b741e92b2829eeae8 – icanbeacoder Apr 13 '16 at 13:37
  • That is a simple example. What I'm asking is how you're doing it. Do you have all the dependencies listed in the main app module? – T J Apr 13 '16 at 13:41
  • yeah, all the dependencies are listed in requires's config (main) and using angularAMD.route for lazy loading controllers for requested routes – icanbeacoder Apr 13 '16 at 13:42
  • Nope, I'm asking how you have distributed your apps dependencies. all of them are listed in the app.js file? (where you declare your app module and define routes in the example) – T J Apr 13 '16 at 13:45
  • nope, not all, only dependencies required for module definition are listed there – icanbeacoder Apr 13 '16 at 13:45
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/109057/discussion-between-icanbeacoder-and-t-j). – icanbeacoder Apr 13 '16 at 13:46

0 Answers0