[]用webpack打包laya会出错

代码如下
require('./libs/laya.core.js');
require('./libs/laya.html.js');

执行时,会报出错误
Uncaught TypeError: Cannot assign to read only property 'document' of object '#<Window>'
出错的句子是
function(global) {'use strict';var window=window||global;var document=document||(window.document={});
                                                                                                                                                               ^这里
已邀请:

Laya_XS

赞同来自:

你这个问题能提供一个示例吗,光看提示不好分析问题!

hhh_DDD

赞同来自:

解决了,问题发生在babel-loader上,使用babel-loader就会出现这个错误

要回复问题请先

商务合作
商务合作