Added comments to the js