This is better, because mainController was in the global scope as a method, we'd rather it be scoped to a module. Where myApp is a better name for a module, the old name is confusing. A module would typically contain many controllers. Additionally, this definition will survive minimizing, since we're storing the variable names (needed for dependency injection) as strings.