how to send json as a response after passport authenticationin node.js

后端 未结 6 495
日久生厌
日久生厌 2021-01-05 06:16

I am trying this git example.

Which works well when I integrated it with my project, but what I want to achieve is to send json as a response to the client/request,

6条回答
  •  春和景丽
    2021-01-05 06:38

    Create new route, e.g.: /jsonSend with res.json in it and make successRedirect: '/jsonSend'. That should do it.

提交回复
热议问题