Sample Code for Angular JS