Refactored JS files.