BeerWithMe/beer-finderWeb — pull request #13 by lpappone (2014-09-24 06:17:54+00:00)
Title: add pre-loading of survey images to fix speed problem

Previously, the first time a user cycled through the survey images, there was a lot of lag. The name of the beer would change, and a second later the picture would. (Subsequent views were ok because the browser cached the images.)

This uses ng-repeat and ng-hide to immediately load all the images, so that there is no lag switching between them. (It also use the controllerAs syntax. It could be done without that, but controllerAs offers additional speed benefits.)