编译时出现问题:X
中的错误/node_modules/jwt simple/lib/jwt.js 13:13-30
找不到模块:错误:无法解析"/Users/shikhapandey/Desktop/Control_Plane/Control Plane ui/node_modules/jwt simple/lib"中的"crypto">
突破性变化:webpack<5用于默认情况下包括node.js核心模块的polyfill。现在已经不是这样了。验证您是否需要此模块,并为其配置polyfill。
如果要包含polyfill,则需要:-添加回退"resolve.fallback:{"crypto":require.resolve("crypto browserfy"(}"-安装"加密浏览"如果不想包含polyfill,可以使用这样的空模块:resolve.fallback:{"crypto":false}
编译时出现问题:X
中的错误/node_modules/jwt simple/lib/jwt.js 13:13-30
找不到模块:错误:无法解析"/Users/shikhapandy/Desktop/CPU/control plane ui/node_modules/jwt simple/lib"中的"crypto">
突破性变化:webpack<5用于默认情况下包括node.js核心模块的polyfill。现在已经不是这样了。验证您是否需要此模块,并为其配置polyfill。
如果要包含polyfill,则需要:-添加回退"resolve.fallback:{"crypto":require.resolve("crypto browserfy"(}"-安装"加密浏览"如果不想包含polyfill,可以使用这样的空模块:resolve.fallback:{"crypto":false}
答案包含在错误中:
- 安装"加密浏览">
- 将回退"resolve.fallback:{"crypto":require.resolve("crypto browserfy"(}"添加到您的Webpack配置中