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

Idea: Bun(/Deno) Support #2

Open
HeyItsBATMAN opened this issue Aug 17, 2023 · 2 comments
Open

Idea: Bun(/Deno) Support #2

HeyItsBATMAN opened this issue Aug 17, 2023 · 2 comments

Comments

@HeyItsBATMAN
Copy link

Bun is a very fast JavaScript runtime supported by steady development, and they have their own SQLite implementation.

Deno also has its own SQLite backend iirc.

Maybe the SQLite backend used for Nebra could be chosen at runtime.

A similar small database project does this:
https://github.com/tr1ckydev/great.db

What do you think of this idea?
If I find the time I can also submit a PR for this.

@aerotoad
Copy link
Owner

aerotoad commented Aug 31, 2023

I'm interested in adding support for Bun since its built-in sqlite3 driver shares the same API as better-sqlite3 therefore it should work out of the box by just changing the way the database instance is created. I will look into it once I'm done implementing the live query and collection events system.

With Deno I have some doubts since apparently the built-in sqlite driver requires using some experimental flags and I'm not fully aware of the API compatibility. Maybe if there is more interest for Deno support it might be worth it.

Nevertheless, I will probably spin out this issue into a different one specific for Bun support.

Thank you for your interest in Neboa!

@drewbitt
Copy link

Ideally, we should be able to drop in https://github.com/tursodatabase/libsql-js for both Bun and Deno as it is better-sqlite3 compatible, although the library is young.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants