After ng-alain logged in using oidc-client, the redirect jump encountered an exception?

ng-alain template. After logging in successfully using oidc-client to connect to ID4,
always displays the following error when calling redirect uri:
Angular is running in the development mode. Call enableProdMode () to enable the production mode.
WebSocket connection to "ws://localhost:4200/sockjs-node/370/l13yjpbj/websocket" failed: WebSocket is closed before the connection is established.

The

page repeatedly shows the login interface jumping to the redirect address. What is the reason for this?
not long after learning the front end, I am not very familiar with websocket.
@ cipchk

Feb.13,2022

is estimated to be caused by auth. One is to add the websocket address to ignores , and the other is to add the corresponding _ allow_anonymous to websoket to ignore authorization check.


I finally found the cause of the problem this afternoon. It's my redirect_url.
first of all, the redirect address written in my project is http://localhost:xxxx/callback (same as ID4), and the actual address displayed by the browser is http://localhost:xxxx/-sharp/callback, so ID4 has been redirected unsuccessfully.
when I change the address to http://localhost:xxxx/-sharp/callback, the address that ID4 jumps becomes http://localhost:xxxx/-sharp/callbackid_token.. Slightly, this is the problem I have to solve next.
by the way, websocket shows normal when closed (closed after login jump) ~

Menu