Notes on AngularJS

in AngularJS

CakePHP Date-time to AngularJS date time

CakePHP created and modified dates are in format “Y-m-d H:i:s” where AngularJS expects date to be in unix format to be able to format.

Using UnderscoreJS with AngularJS

I have used underscoreJS earlier and I must say that it is an awesome plugin that I mostly use wherever I need to deal with lot of JavaScript. This question on Stack Overflow shows you how you can install it with your AngularJS project.

Sharing code between controllers

Initially, I struggled finding what could be a proper way to share common functionality in AngularJS. For example, I was using multiple controllers in my app and I wanted a common place to show error, success, info messages at one place.

This could be achieved in AngularJS by sharing a service.

Loading Bar

I wanted to use a loading progress bar, something similar used on YouTube. Finally I found a plugin, Angular Loading Bar, that calculates correct progress time based on simultaneous HTTP requests and works fine with AngularJS project.