cbl_dart 1.0.0-beta.0 cbl_dart: ^1.0.0-beta.0 copied to clipboard
Couchbase Lite for pure Dart apps: An embedded, NoSQL JSON Document Style database, supporting Blobs, Encryption, N1QL Queries, Live Queries, Full-Text Search and Data Sync.
Couchbase Lite for pure Dart apps, such as servers and CLIs.
The Couchbase Lite API is in the cbl
package. This package is enabling
the use of cbl
in pure Dart apps.
This package is in beta. Use it with caution and report any issues you see.
🎯 Platform Support #
Platform | Version | Note |
---|---|---|
macOS | >= 10.14 | |
Linux | == Ubuntu 20.04-x86_64 | |
Windows | >= 10 | 🚧 Not yet implemented |
🔌 Getting Started #
-
Add
cbl
andcbl_dart
as dependencies:dependencies: cbl: ... cbl_dart: ...
-
Initialize Couchbase Lite before using it. This is also where you select the edition of Couchbase Lite you want to use:
import 'package:cbl_dart/cbl_dart.dart'; Future<void> initCouchbaseLite() async { await CouchbaseLiteDart.init(edition: Edition.community); }
Note that
init
downloads the needed native libraries if they have not already been cached. See the documentation forCouchbaseLiteDart.init
for more information.⚖️ You need to comply with the Couchbase licensing terms of the edition of Couchbase Lite you select.
Default database directory #
When opening a database without specifying a directory, the current working
directory will be used. CouchbaseLiteDart.init
allows you to specify a
different default directory.
💡 Where to go next #
- Check out the example app in the Example tab.
- Look at the usage examples for
cbl
(go to the latest prerelease).
⚖️ Disclaimer #
⚠️ This is not an official Couchbase product.