Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to show a loading indicator when loading the app at the first time

I have to load many files for my AngularJs single page application, like angular.js, jquery.js, bootstrap.js, bootstrap.css, some_plugins.js, my_main.js and others,

It take some time to load the entire app, so I want to show a loading indicator (a spinner for example) in a void page until all the js and css files load and then display the content.

like image 327
Sn0opr Avatar asked Apr 26 '14 21:04

Sn0opr


1 Answers

For Angular Apps use Angular Loading Bar. Looks like this.

  • Would apply to whenever an XHR request goes out in angular
  • Can specify which request to not display loading icon
  • Only displayed when the request causes user to wait
  • Can be styled to your liking
  • Injected into the services module and just works
like image 67
Equan Simmonds Avatar answered Oct 26 '22 08:10

Equan Simmonds