Giter Club home page Giter Club logo

Comments (5)

DjDeveloperr avatar DjDeveloperr commented on August 15, 2024

The current API is inspired from Node.js better-sqlite3 module, as a result of rewrite that took place a while ago: #44

It's a pretty simple and synchronous API that allows making best of sqlite3 performance. I see that node-sqlite3 is callback based & non-blocking/asynchronous, which could be a bottleneck.

So I think a separate wrapper is a preferable option, since the current API seems better in terms of simplicity and performance (see https://www.npmjs.com/package/better-sqlite3 for some performance comparison, and this module performs even better than better-sqlite3). Currently, the high performance sqlite3 bindings in Node.js (better-sqlite3), Deno (sqlite3) and Bun (bun:sqlite) ecosystems all have this similar API.

from sqlite3.

JumpLink avatar JumpLink commented on August 15, 2024

@DjDeveloperr Thanks for the answer, that is very good to know that the API is based on better-sqlite3!

There are also drivers in TypeORM for better-sqlite3, so maybe I should just output this package as better-sqlite3, if that would work I could have saved myself the wrapper 😅. Do you think there are still big differences regarding better-sqlite3?

Edit:
Okay, I tested it once, there seem to be some differences in the return values, so that would also need adjustments, the question is which is more complex...

from sqlite3.

DjDeveloperr avatar DjDeveloperr commented on August 15, 2024

@JumpLink Using better-sqlite3 driver sounds like a great idea. I can try to help get that to work. There shouldn't be much big differences, which one are you running into here?

from sqlite3.

JumpLink avatar JumpLink commented on August 15, 2024

@DjDeveloperr I can create a simple example for this issue, than other developers like you can test it by himself

from sqlite3.

JumpLink avatar JumpLink commented on August 15, 2024

@DjDeveloperr Here the example: https://github.com/JumpLink/deno-typeorm-sqlite-example with preconfigured settings for debugging Deno and Node.js in VSCode.

from sqlite3.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.