【发布时间】:2016-02-07 16:05:07
【问题描述】:
我正在尝试使用 Closure 模板让 Google Closure 库正常工作,但是当我运行我的应用程序时,它会引发错误 soyutils_usegoog.js:74 Uncaught TypeError: Cannot read property 'StringBuffer' of undefined。
我已经研究了所有内容,添加了 goog deps.js 文件,移动了一些东西,但我仍然无法让它运行。 所以我然后从CLosure网站复制了确切的例子来尝试找出它,它仍然给我同样的错误。 我在这里尝试了第一个简单的例子:https://developers.google.com/closure/templates/docs/helloworld_js
如果我在控制台中查询goog.string.StringBuffer,它会返回一个函数,它似乎是最后加载该文件。
【问题讨论】:
标签: google-closure google-closure-library google-closure-templates