Relative Content

Tag Archive for fluttersynchronizationcouchdbreplicationoffline

Flutter Sync with SQFLite and CouchDB

Future<void> startReplication(Database database) async { final replicator = await Replicator.create(ReplicatorConfiguration( database: database, target: UrlEndpoint(Uri.parse('ws://localhost:5984/chatapp')), continuous: true, authenticator: BasicAuthenticator(username: 'admin', password: 'admin'), replicatorType: ReplicatorType.pushAndPull, headers: {'CustomHeader': 'SomeHeaderValue'}, )); await replicator.start(); }