Skip to content
Discussion options

You must be logged in to vote

It works pretty well. Had a minor glitch figuring out custom signin pages as I thought of using Link with custom href or button with custom fetch but it turns out using getProviders in getServerSideProps was the way.

I did manage to make my code extremely small by offloading auth to next-auth. ~800 LOCs replaced with ~100 LOCs. See this commit.

This is the complete code on next-auth branch → https://github.com/deadcoder0904/twitter-api-v2-3-legged-login-using-next-connect/tree/next-auth

If you are logged in, it'll show the app in the root route /. If you are logged out, it will show login button on the same root route /.

Replies: 3 comments 7 replies

Comment options

You must be logged in to vote
2 replies
@deadcoder0904
Comment options

@balazsorban44
Comment options

Comment options

You must be logged in to vote
5 replies
@balazsorban44
Comment options

@deadcoder0904
Comment options

@balazsorban44
Comment options

@SlinkyPotato
Comment options

@balazsorban44
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by deadcoder0904
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
3 participants