Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

In Angular Seed project, what is point of index-async.html?

I've been getting started with Angular JS and using it as a front-end to integrate with a Play Framework POC. I've already worked through the tutorial.

I cloned my front end from the seed project on github. It has an app/index.html (which I'm using as my main page) and an app/index-async.html. What is the point of the latter? Is it really necessary?

like image 200
Alan Avatar asked Jul 19 '12 17:07

Alan


1 Answers

The two files are interchangeable, and you can use either one to build your application. index-async.html loads scripts asynchronously, which might give you a faster bootstrap time. index.html loads scripts synchronously, which is often a bit slower, but the intention is that the code is easier to understand for someone learning to use the framework.

To read more about asynchronous bootstrapping, check out the docs here: http://docs.angularjs.org/guide/bootstrap

like image 58
btford Avatar answered Oct 10 '22 06:10

btford