Integrated with the RequireJS framework and break original code into several modules