在JS 脚本中,运行 var xhttp = new XMLHttpRequest;报错,提示:ReferenceError: XMLHttpRequest is not defined;
原因:xmlhttprequest 不是Node 内置的,需要单独安装:
安装命令:npm install xmlhttprequest
参考内容:https://stackoverflow.com/questions/32604460/xmlhttprequest-module-not-defined-found
Maximum call stack size exceeded
解决:关闭脚本编辑器,关闭终端,再重启、运行命令,安装成功
参考文档:https://blog.csdn.net/weixin_43869192/article/details/90377124