@powersync/react-native 0.0.0-dev-20250711131120 → 0.0.0-dev-20250714151300
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -22,6 +22,4 @@ export declare class PowerSyncDatabase extends AbstractPowerSyncDatabase {
|
|
|
22
22
|
protected openDBAdapter(options: PowerSyncDatabaseOptionsWithSettings): DBAdapter;
|
|
23
23
|
protected generateBucketStorageAdapter(): BucketStorageAdapter;
|
|
24
24
|
protected generateSyncStreamImplementation(connector: PowerSyncBackendConnector, options: RequiredAdditionalConnectionOptions): AbstractStreamingSyncImplementation;
|
|
25
|
-
readLock<T>(callback: (db: DBAdapter) => Promise<T>): Promise<T>;
|
|
26
|
-
writeLock<T>(callback: (db: DBAdapter) => Promise<T>): Promise<T>;
|
|
27
25
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { AbstractPowerSyncDatabase } from '@powersync/common';
|
|
2
2
|
import { ReactNativeRemote } from '../sync/stream/ReactNativeRemote';
|
|
3
3
|
import { ReactNativeStreamingSyncImplementation } from '../sync/stream/ReactNativeStreamingSyncImplementation';
|
|
4
|
-
import { ReactNativeQuickSqliteOpenFactory } from './adapters/react-native-quick-sqlite/ReactNativeQuickSQLiteOpenFactory';
|
|
5
4
|
import { ReactNativeBucketStorageAdapter } from './../sync/bucket/ReactNativeBucketStorageAdapter';
|
|
5
|
+
import { ReactNativeQuickSqliteOpenFactory } from './adapters/react-native-quick-sqlite/ReactNativeQuickSQLiteOpenFactory';
|
|
6
6
|
/**
|
|
7
7
|
* A PowerSync database which provides SQLite functionality
|
|
8
8
|
* which is automatically synced.
|
|
@@ -28,10 +28,10 @@ export class PowerSyncDatabase extends AbstractPowerSyncDatabase {
|
|
|
28
28
|
return defaultFactory.openDB();
|
|
29
29
|
}
|
|
30
30
|
generateBucketStorageAdapter() {
|
|
31
|
-
return new ReactNativeBucketStorageAdapter(this.database
|
|
31
|
+
return new ReactNativeBucketStorageAdapter(this.database);
|
|
32
32
|
}
|
|
33
33
|
generateSyncStreamImplementation(connector, options) {
|
|
34
|
-
const remote = new ReactNativeRemote(connector
|
|
34
|
+
const remote = new ReactNativeRemote(connector);
|
|
35
35
|
return new ReactNativeStreamingSyncImplementation({
|
|
36
36
|
adapter: this.bucketStorageAdapter,
|
|
37
37
|
remote,
|
|
@@ -41,16 +41,7 @@ export class PowerSyncDatabase extends AbstractPowerSyncDatabase {
|
|
|
41
41
|
},
|
|
42
42
|
retryDelayMs: options.retryDelayMs,
|
|
43
43
|
crudUploadThrottleMs: options.crudUploadThrottleMs,
|
|
44
|
-
identifier: this.database.name
|
|
45
|
-
logger: this.logger
|
|
44
|
+
identifier: this.database.name
|
|
46
45
|
});
|
|
47
46
|
}
|
|
48
|
-
async readLock(callback) {
|
|
49
|
-
await this.waitForReady();
|
|
50
|
-
return this.database.readLock(callback);
|
|
51
|
-
}
|
|
52
|
-
async writeLock(callback) {
|
|
53
|
-
await this.waitForReady();
|
|
54
|
-
return this.database.writeLock(callback);
|
|
55
|
-
}
|
|
56
47
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@powersync/react-native",
|
|
3
|
-
"version": "0.0.0-dev-
|
|
3
|
+
"version": "0.0.0-dev-20250714151300",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"registry": "https://registry.npmjs.org/",
|
|
6
6
|
"access": "public"
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"homepage": "https://docs.powersync.com/",
|
|
26
26
|
"peerDependencies": {
|
|
27
27
|
"@journeyapps/react-native-quick-sqlite": "^2.4.6",
|
|
28
|
-
"@powersync/common": "0.0.0-dev-
|
|
28
|
+
"@powersync/common": "0.0.0-dev-20250714151300",
|
|
29
29
|
"react": "*",
|
|
30
30
|
"react-native": "*"
|
|
31
31
|
},
|
|
@@ -35,8 +35,8 @@
|
|
|
35
35
|
}
|
|
36
36
|
},
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@powersync/common": "0.0.0-dev-
|
|
39
|
-
"@powersync/react": "
|
|
38
|
+
"@powersync/common": "0.0.0-dev-20250714151300",
|
|
39
|
+
"@powersync/react": "0.0.0-dev-20250714151300"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
42
|
"@craftzdog/react-native-buffer": "^6.0.5",
|