Angularjs 角度指令替换

Angularjs 角度指令替换,angularjs,Angularjs,有人能告诉我为什么下面的指令不起作用吗 angular.module('app',[]). directive('Test',function() { return { restrict : 'E', replace : true, template :'<h3>Test Test Test Test</h3>' }; }); angular.module('app',[])。 指令('Test',函数(){ 返回{ 限制:'E'

有人能告诉我为什么下面的指令不起作用吗

angular.module('app',[]).
directive('Test',function() {
  return {
    restrict : 'E',
    replace : true,
    template :'<h3>Test Test Test Test</h3>'
    };
  });
angular.module('app',[])。
指令('Test',函数(){
返回{
限制:'E',
替换:正确,
模板:“测试”
};
});
Html



如果我理解正确,我希望它在h3中显示
Test
,但它不显示,知道为什么吗?

我不知道为什么,但如果您将指令命名为
指令('Test',function(){
,它工作。

它显示了,这很奇怪,他们在指令匹配中提到了它
 <body ng-app="app">
    <Test></Test>
  </body>