我正在尝试 toastr,但我不断收到一个奇怪的 TypeError,这对我来说没有任何意义。
TypeError: Cannot read property 'extend' of undefined
at getOptions (http://localhost:3000/bower_components/toastr/toastr.js:391:25)
我用 yeoman gulp-angular 搭建了我的项目,并将 toastr 正确地注入到我想测试它的控制器中。我试过的线路很简单:
toastr.info('A message.');
toastr 出现在页面中 - 由 gulp 任务插入。如何找出这里出了什么问题?