JavaScript scripts moved to files and located at static folder. Refactoring.