Moved JS to its own file