Refactored Javascript Code and Documentation.

Change-Id: I0fe52bb1e9442843baecf17c0316f2e0323c6960
Release 1.1.1

Change-Id: I4f0639cbbf050f401260c839813c43798480dd14