sqljs 2.0.0 copy "sqljs: ^2.0.0" to clipboard
sqljs: ^2.0.0 copied to clipboard

Dart 1 only

A dart wrapper for kipken/sql.js

sqljs.dart #

A dart wrapper for kipken/sql.js

Usage #

    import 'package:sqljs/sqljs.dart';

    main() {
      var db = new Database();
      var statement = """
        CREATE TABLE hello (a int, b char);
        INSERT INTO hello VALUES (0, 'hello');
        INSERT INTO hello VALUES (1, 'world');
      """;
      db.run(statement);
      var res = db.exec("SELECT * FROM hello");
      for (var value in res.first.values) {
        print('row: ${value[0]} ${value[1]}');
      }
    }

Generating #

This package uses dart_js_facade_gen. To generate a library from the typescript definition file run:

dart_js_facade_gen lib/sqljs.d.ts > lib/sqljs.dart

Features and bugs #

Please file feature requests and bugs at the issue tracker.

0
likes
20
points
3
downloads

Publisher

unverified uploader

Weekly Downloads

A dart wrapper for kipken/sql.js

Repository (GitHub)
View/report issues

License

BSD-3-Clause (license)

Dependencies

js, resource

More

Packages that depend on sqljs