选择链接后,CasperJS屏幕截图显示为空白

时间:2014-01-18 01:15:13

标签: dojo casperjs

使用casperJS脚本,成功登录应用程序并单击链接后,将抛出以下错误,并且网页显示为空白:

  ERROR: TypeError: 'undefined' is not a function (evaluating  
  'g.getItem.bind(g)')  
  TRACE:  
  -> scripts/dojo/dojo/dojo.js: 20  
  ERROR: TypeError: 'undefined' is not a function (evaluating  
  'g.getItem.bind(g)')  

应用程序构建在dojo之上。

1 个答案:

答案 0 :(得分:0)

您编写了一些尝试使用Function.prototype.bind的代码。 PhantomJS中不存在Function.prototype.bind。您需要更改代码才能使用dojo/_base/lang.hitch