Moved the JS class

I also replaced unnecessary endls with \ns