类型错误:无效的“instanceof”操作数KeyObject

问题描述 投票:0回答:1
When I try to log in to the system where I have defined the username and password, I get the error "TypeError: invalid 'instanceof' operand KeyObject". I edited angular.js and other contents, but I have not been able to fully solve the problem.
I am using the following versions:

Angular CLI:16.2.2 节点:18.18.0 包管理器:npm 9.8.1 操作系统:win32 x64

enter code here
角度:16.2.8 ...动画、常见、编译器、编译器-cli、核心、表单 ...本地化、平台浏览器、平台浏览器动态 ...平台服务器、路由器 @Angular-devkit/建筑师0.1602.6 @Angular-devkit/build-Angular 16.2.6 @Angular-devkit/核心 16.2.2 @angular-devkit/schematics 16.2.6 @角度/cdk 16.2.7 @角度/cli 16.2.2 @角度/火7.6.1 @角度/材料16.2.7 @角度/材料力矩适配器16.2 @ngtools/webpack 16.2.6 @nguniversal/建设者16.2.0 @nguniversal/express-engine @schematics/角度 16.2.0 rxjs 7.8.1 打字稿 5.1.6 网页包 5.88.2 zone.js 0.13.3

我可以获得“ERROR TypeError: invalid 'instanceof' operand KeyObject”的解决方案建议。

jwt typeerror tsconfig angular16
1个回答
0
投票

注意 Angular 16 的兼容包安装! 为了解决我自己的问题,您应该安装“npm i browser-crypto”作为与 jsonwebtoken 9.0.2 软件的 8.5.1 版本兼容的附加包。另外,tsconfig.json 文件的内容: "browser": {"crypto": true,} 和 “路径”:{“加密”:[“node_modules / crypto-browserify”] 您应该将其更新为 .

© www.soinside.com 2019 - 2024. All rights reserved.