Prectice of angular javscript