How to can I make this code that I have minification friendly?
MyModule.config(['$provide',function($provide) {
$provide.decorator("$exceptionHandler", function($delegate,$injector) {
I can't seem to do this:
$provide.decorator("$exceptionHandler" , "$delegate","$injector", function($delegate,$injector) {
You are missing the [
. The pattern is the same that you successfully applied for config
:
$provide.decorator("$exceptionHandler" , [ "$delegate","$injector",
function($delegate,$injector) {
来源:https://stackoverflow.com/questions/23946996/how-to-make-angular-decorators-minification-friendly