What does passport.js do and why we need it?

后端 未结 2 1358
-上瘾入骨i
-上瘾入骨i 2021-02-03 23:35

I am not familiar with user authentication in Node.js, now I am trying to create a website with a login system. I have managed to make it work using the code snippets from the w

2条回答
  •  [愿得一人]
    2021-02-04 00:21

    To me it's unnecessary.

    It's not saving me any work. I have to write the configuration, the callback, and the user schema. To me, it's just easier for me to just write a middleware for that.

    And I don't see there is any security enforcement I am getting cuz I am writing my own verify callback anyway.

    So, I don't see any reason that I should use it.

提交回复
热议问题