Dojo nested requires on IE7 and IE8 causes Invalid Argument Exception

怎甘沉沦 提交于 2019-12-11 10:28:41

问题


Here is the simplest example I could come up with. I keep getting an Invalid Argument exception being thrown on the second require call in IE7 and IE8. This works fine in IE9+, Chrome and Firefox. Very frustrating. Debugging this through IE developer tools has not been helpful.

<script type="text/javascript">
   require(["dojo/request/xhr", "dojo/domReady"],
      function(xhr){
         xhr("Servlet?arg=1")
           .then(function(data) {
              try {
                   test()
               } catch(e) {
                  cpb.consoleLog(e.number);
                  cpb.consoleLog(e.description);
                  throw e;
               }
          });
      });
  function test() {
      require(['dojox/charting/Chart'], function (Chart) {
           // simulate problem
      });
  }
</script>

来源:https://stackoverflow.com/questions/13074513/dojo-nested-requires-on-ie7-and-ie8-causes-invalid-argument-exception

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!