WebPack TypeError:无法读取未定义的属性“请求"

WebPack TypeError:无法读取未定义的属性“请求

问题描述:

我继承了一个现有的Angular2项目.当我运行NPM start时,出现一个很长的错误,始于:

I've inherited an existing Angular2 project. When I run NPM start I get a long error beginning with:

HTML Webpack插件:

Html Webpack Plugin:

TypeError:无法读取未定义的属性"request"
...

TypeError: Cannot read property 'request' of undefined
...

完整错误输出: http://textuploader.com/d5n25

任何想法意味着什么以及如何调试它以找出问题所在的代码文件/代码行?

Any ideas what this means and how I can debug this to find out the file/line of code that is the problem?

如果该信息有帮助,也可以在Windows 8.1上使用.

Also on Windows 8.1 if that information helps.

我遇到了同样的问题.我的人来自多个版本的webpack和HTML Webpack插件.

I had the same issue. Mine came from multiple versions of both webpack and HTML Webpack Plugin.

使用npm ls webpack html-webpack-plugin检查是否存在版本冲突,并删除不需要的版本.

Check with npm ls webpack html-webpack-plugin whether you are having version conflicts and remove the one you don't need.