resqlite_js 0.1.0 copy "resqlite_js: ^0.1.0" to clipboard
resqlite_js: ^0.1.0 copied to clipboard

SQLite JavaScript extension support for resqlite.

resqlite_js #

SQLite JS extension support for package:resqlite.

This package exposes SQLite JS's native entrypoint as a ResqliteExtension value for Database.open.

import 'package:resqlite/resqlite.dart';
import 'package:resqlite_js/resqlite_js.dart';

final db = await Database.open(
  'app.db',
  extensions: [SqliteJsExtension()],
);

final rows = await db.select('SELECT js_version() AS version');

Advanced per-connection setup can be added with onRegister:

SqliteJsExtension(
  onRegister: (ext) {
    ext.execute('CREATE TEMP TABLE js_setup(value TEXT)');
  },
);

The bundled native binaries are derived from the sqlite_js Dart package and are covered by the license in LICENSE.

0
likes
130
points
11
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

SQLite JavaScript extension support for resqlite.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

code_assets, hooks, path, resqlite

More

Packages that depend on resqlite_js