cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

Driver for Deno.land

There is a driver available for Deno?

8 REPLIES 8

Hi @shinspiegel,

Welcome to the Neo4j community!

There is no official (or afaik unofficial) driver for Deno.

What happens when you try to load the nodejs driver?

Best,
ABK

Hi @shinspiegel CC @abk

I ported Neo4j Driver version 4.3 to Deno earlier this year: https://github.com/technotes-org/neo4j-javascript-driver

If you're curious the changes that were required, the diff can be seen here.

Mostly it was a matter of changing file paths/extensions in the import statements, but there were actually some typing bugs that Deno caught which somehow weren't caught in the upstream repo, like this import of ALL which doesn't exist in request-message and had to be updated to FETCH_ALL.

Alternatively: since Deno implements web APIs, you should also be able to just use the "browser" version of neo4j-javascript-driver as described in this thread, but it won't have the TypeScript type info. I preferred to port the driver to get full TypeScript support.

Thnx! This sounds good, will give it a try!
Would be great to have an official, always up2date Deno build directly from the neo4j team

Hi @bradenmacdonald ,

Thanks for the work that went into that port! And thanks @chris3 for the reminder about this thread 😉

I've had a chat with the driver team and Deno has come up on their future planning wall. Would you @bradenmacdonald be up for submitting a pull request with your changes?

Best,
ABK

@abk That's great to hear. Sure, I'd be happy to. Just may take me a couple of days to get to it 🙂

Fantastic. 🙂

No rush, at all. We're grateful for the contribution!

@abk Well it took me much longer than I'd hoped.... But I got some time over the holidays and have refreshed my Deno port to be based on the latest version 4.4, and I've opened four pull requests to contribute the changes: Proposal: A tool for generating a deno-optimized version of the driver by bradenmacdonald · Pull Req...


For those reading this and looking for a Deno version that can be used today, I have also posted it to deno.land at https://deno.land/x/neo4j_lite_client

Cheers!

That is fantastic @bradenmacdonald !