Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat: better-auth#71

Open
harshsbhat wants to merge 4 commits intoupstash:main from
harshsbhat:better-auth
Open

feat: better-auth #71
harshsbhat wants to merge 4 commits intoupstash:main from
harshsbhat:better-auth

Conversation

@harshsbhat
Copy link

@harshsbhat harshsbhat commented Apr 7, 2025

No description provided.

@harshsbhat harshsbhat marked this pull request as ready for review April 8, 2025 04:49
Copy link

Hey, Thank you for PR. as someone who has implemented better auth using JStack.

const sql = neon(process.env.DATABASE_URL!);

This will not work for cloudflare workers, due to process.env being undefined.

You need to create the auth as a hono middleware and use the db from the middleware, since it binds the env variables.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should be done via a jstack middleware as well. using use

Copy link
Author

@harshsbhat harshsbhat Apr 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes! I realized this after reviewing the https://www.better-auth.com/docs/integrations/hono yesterday. Give me a day. I will do the fixes. Also, the env ones.

Thanks for taking the time to review tho

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes! I realized this after reviewing the https://www.better-auth.com/docs/integrations/hono yesterday. Give me a day. I will do the fixes. Also, the env ones.

Thanks for taking the time to review tho

image image

Hopefully this helps, I already implemented this for our company 2 months ago, publishing the code so it helps you. Good luck brother

harshsbhat reacted with eyes emoji
Copy link
Author

@harshsbhat harshsbhat Apr 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for sharing this. We'll implement this tomorrow after college

Copy link

@un3trois7 un3trois7 Apr 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

eager to see your implementation! the jstack cli def need a proper better-auth setup on launch

Copy link

yansircc commented May 3, 2025

Any update on this PR? Better-auth or next-auth integration would be a very good implement!

Copy link
Author

@yansircc Yes, I can work on this today or tomorrow ( since it's a weekend )

yansircc reacted with eyes emoji

Copy link

yansircc commented May 3, 2025

@harshsbhat You have no idea how much time I spent on auth, and in the end, I had to use Clerk's JWT solution.

Rame0ne reacted with eyes emoji

Copy link

ziyadev commented Sep 24, 2025

@harshsbhat still you working on this? If not, may i handle it ?

Copy link
Author

@ziyadev go for it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

2 more reviewers

@SamHoque SamHoque SamHoque left review comments

@un3trois7 un3trois7 un3trois7 left review comments

Reviewers whose approvals may not affect merge requirements

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /