cbl 3.3.0-dev.5 copy "cbl: ^3.3.0-dev.5" to clipboard
cbl: ^3.3.0-dev.5 copied to clipboard

Couchbase Lite is an embedded, NoSQL JSON Document Style database, supporting Blobs, Encryption, SQL++ Queries, Live Queries, Full-Text Search and Data Sync.

example/lib/main.dart

// ignore_for_file: avoid_print

import 'package:cbl/cbl.dart';

/// You need to specify how to access the native libraries, on top of which
/// `cbl` is implemented.
LibrariesConfiguration getLibraries() {
  throw UnimplementedError('TODO');
}

Future<void> main() async {
  // Couchbase Lite needs to be initialized before it can be used.
  await CouchbaseLite.init(libraries: getLibraries());

  final db = await Database.openAsync('chat-app');
  final messages = await db.createCollection('messages');

  final doc = MutableDocument({
    'type': 'message',
    'body': 'Heyo',
    'from': 'Alice',
  });

  await messages.saveDocument(doc);

  await db.close();
}
70
likes
0
points
10.1k
downloads

Publisher

verified publishercbl-dart.dev

Weekly Downloads

Couchbase Lite is an embedded, NoSQL JSON Document Style database, supporting Blobs, Encryption, SQL++ Queries, Live Queries, Full-Text Search and Data Sync.

Homepage
Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

archive, cbl_libcblite_api, cbl_libcblitedart_api, characters, collection, ffi, http, meta, path, stream_channel, synchronized, web_socket_channel

More

Packages that depend on cbl