Updateding the js file which I want to mange from the gem #2 

fixes #2 and fixes #1