dependency injection for requirejs.