Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/angularjs/20.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Angularjs 如果使用“严格”创建问题,则DOM不会仅更新带有replace true的模板_Angularjs - Fatal编程技术网

Angularjs 如果使用“严格”创建问题,则DOM不会仅更新带有replace true的模板

Angularjs 如果使用“严格”创建问题,则DOM不会仅更新带有replace true的模板,angularjs,Angularjs,我正在使用上述代码,但DOM没有更新。不使用strict不会产生问题 'use strict'; angular.module('$praveen.directives').directive('currentTime', function () { return function (scope, elem, attr) { elem.html("Hello"); } });

我正在使用上述代码,但DOM没有更新。

不使用strict不会产生问题
'use strict';
angular.module('$praveen.directives').directive('currentTime',
    function () {
        return function (scope, elem, attr) {
            elem.html("Hello");
        }
    });