require js refactoring