Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

auth/neon-adapter is not currently in the npm registry #12506

Open
stevenfojas670 opened this issue Jan 15, 2025 · 5 comments
Open

auth/neon-adapter is not currently in the npm registry #12506

stevenfojas670 opened this issue Jan 15, 2025 · 5 comments
Labels
triage Unseen or unconfirmed by a maintainer yet. Provide extra information in the meantime.

Comments

@stevenfojas670
Copy link

What is the improvement or update you wish to see?

Just wanted to make it known that the npm package auth/neon-adapter is not currently in the npm registry.

Is there any context that might help us understand?

I was trying to set up my auth.js with neon and found auth/neon-adapter in the docs, but it's inactive.

Does the docs page already exist? Please link to it.

https://authjs.dev/getting-started/adapters/neon

@stevenfojas670 stevenfojas670 added the triage Unseen or unconfirmed by a maintainer yet. Provide extra information in the meantime. label Jan 15, 2025
@halvaradop
Copy link
Contributor

halvaradop commented Jan 21, 2025

Yes, you are right @auth/neon-adapter is currently not in npm and the reason it exists in the documentation and not in npm, is because when you create a pull request and then merge it creates a new version of the auth-docs for that reason there is documentation on how to use the package, because normally when you add an adapter or provider you should include the documentation on how to use the adapter/provider, however, it does not mean that the packages are published or delivered.

I hope you understand the reason. The only thing we can do is wait until its first release or get in touch with a maintainer of the auth.js ecosystem.

@REDAMANS
Copy link

I found out that Neon documentation provides an integration guide for Auth.js, and it does not require the nonexistent npm package.

@aknobloch
Copy link

aknobloch commented Feb 5, 2025

Since someone thumbs-downed the last comment, figured I'd add my own two cents. The integration guide linked worked for me as well, just use a bit of common sense on what you need for your project. For example, I didn't actually need the Resend integration, the todo's or associated code, or the API handler setup. Also noteworthy that I didn't globally configure the pool outside the request handler, per Auth.js recommendations.

So, really, just npm install the pg-adapter instead, and use that as a drop-in replacement from the Auth.js docs.

@peterbakonyi05
Copy link

For anyone else blocked on this: I ended up copying the single index.ts file from the source to my project with a TODO. Once it's released, I can just install the npm package and remove the copied source code. Takes 2 mins and does the job.

@aknobloch
Copy link

aknobloch commented Feb 5, 2025

@peterbakonyi05, I wouldn't recommend that approach. If you want to use the neon-adapter, npm supports installing packages from GitHub directly. The advantage of doing that is you have greater control (e.g. specifying target branches) and you also will be staying up to date with source changes as they happen. Copying the file directly means you're subject to breakages and maintaining your local source with upstream manually.

All that said, once again the pg-adapter looks to be a drop-in replacement, and is published to the registry!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage Unseen or unconfirmed by a maintainer yet. Provide extra information in the meantime.
Projects
None yet
Development

No branches or pull requests

5 participants