mirror of
https://github.com/aljazceru/turso.git
synced 2025-12-26 04:24:21 +01:00
This adds `Database.prepare()` and `Statement.all()` APIs to the Wasm bindings so that you can actually get something useful out of the library.
9 lines
173 B
JavaScript
9 lines
173 B
JavaScript
import { Database } from 'limbo-wasm';
|
|
|
|
const db = new Database('hello.db');
|
|
|
|
const stmt = db.prepare('SELECT * FROM users');
|
|
|
|
const users = stmt.all();
|
|
|
|
console.log(users); |