相关疑难解决方法(0)

使用指令控制器进行角度缩小?

如果我有以下内容:

myapp.directive('directivename', ...

    return {
        ...
        restrict: 'E',
        controller: MyController,
        ...
    }

    function MyController($scope, $somethingelse) {
        // Contents of controller here
    }
);
Run Code Online (Sandbox Code Playgroud)

如何修改它以便MyController在缩小时不会被破坏?我收到以下错误:

错误:[$ injector:unpr]未知提供者:eProvider < - e

javascript minify angularjs angularjs-directive angularjs-controller

7
推荐指数
1
解决办法
3697
查看次数