Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/fortran/2.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 typeahead模板url未在模板中呈现{{}表达式_Angularjs_Angular Ui Bootstrap - Fatal编程技术网

Angularjs typeahead模板url未在模板中呈现{{}表达式

Angularjs typeahead模板url未在模板中呈现{{}表达式,angularjs,angular-ui-bootstrap,Angularjs,Angular Ui Bootstrap,我有这个Angular.js UI引导问题。typeahead模板url=“typeahead/bind node.html”未在typeahead模板中呈现表达式的{{}。我不知道为什么。在Chromium调试器中,我在元素检查器中验证了这一点,其中存在文本{{match},而不是计算的表达式 我还使用“console.log()”验证了返回到getNodeLabel($viewValue)的对象是否正常 Html: 提前键入html: <script type="text/ng-

我有这个Angular.js UI引导问题。
typeahead模板url=“typeahead/bind node.html”
未在typeahead模板中呈现表达式的
{{}
。我不知道为什么。在Chromium调试器中,我在元素检查器中验证了这一点,其中存在文本
{{match}
,而不是计算的表达式

我还使用“console.log()”验证了返回到
getNodeLabel($viewValue)
的对象是否正常

Html:



提前键入html:

<script type="text/ng-template" id="bind-node.html">
 <a>
 {{match}}
 <span bind-html-unsafe="match.label | typeaheadHighlight:query" class="ng-binding">
 <i>{{match.label}}</i>
 <h1>{{match}}</h1>
 </span>
 </a>
</script>

{{match}}
{{match.label}
{{match}}

id=“bind node.html”
需要是
id=“typeahead/bind node.html”
不匹配
dropDownItem
dropDownItems
?当你说它不是“呈现表达式的{}}”时,你在html中得到的是空格还是
{}
{}}中的空格?我得到的是实际的ascii括号
{}}
在html中。这很奇怪。通常这意味着没有编译HTML模板,否则在呈现的HTML中不应该看到任何
{{}}
。你能提供一个打劫吗?不,我不能。。。。UI引导
typeahead
的代码中没有自己的指令/控制器吗?该区域是否存在导致模板无法渲染的错误?
<script type="text/ng-template" id="bind-node.html">
 <a>
 {{match}}
 <span bind-html-unsafe="match.label | typeaheadHighlight:query" class="ng-binding">
 <i>{{match.label}}</i>
 <h1>{{match}}</h1>
 </span>
 </a>
</script>