File tree Expand file tree Collapse file tree 1 file changed +4
-23
lines changed
packages/powersync-op-sqlite Expand file tree Collapse file tree 1 file changed +4
-23
lines changed Original file line number Diff line number Diff line change @@ -74,9 +74,7 @@ To load additional SQLite extensions include the `extensions` option in `sqliteO
7474
7575``` js
7676sqliteOptions: {
77- extensions: [
78- { path: libPath, entryPoint: ' sqlite3_powersync_init' }
79- ]
77+ extensions: [{ path: libPath, entryPoint: ' sqlite3_powersync_init' }];
8078}
8179```
8280
@@ -87,38 +85,21 @@ Example usage:
8785``` ts
8886import { getDylibPath } from ' @op-engineering/op-sqlite' ;
8987
90- let libPath: string
88+ let libPath: string ;
9189if (Platform .OS === ' ios' ) {
92- libPath = getDylibPath (' co.powersync.sqlitecore' , ' powersync-sqlite-core' )
90+ libPath = getDylibPath (' co.powersync.sqlitecore' , ' powersync-sqlite-core' );
9391} else {
9492 libPath = ' libpowersync' ;
9593}
9694
9795const factory = new OPSqliteOpenFactory ({
9896 dbFilename: ' sqlite.db' ,
9997 sqliteOptions: {
100- extensions: [
101- { path: libPath , entryPoint: ' sqlite3_powersync_init' }
102- ]
98+ extensions: [{ path: libPath , entryPoint: ' sqlite3_powersync_init' }]
10399 }
104100});
105101```
106102
107- ## Using the Memory Temporary Store
108-
109- For some targets like Android 12/API 31, syncing of large datasets may cause disk IO errors due to the default temporary store option (file) used.
110- To resolve this you can use the ` memory ` option, by adding the following configuration option to your application's ` package.json `
111-
112- ``` json
113- {
114- // your normal package.json
115- // ...
116- "op-sqlite" : {
117- "sqliteFlags" : " -DSQLITE_TEMP_STORE=2"
118- }
119- }
120- ```
121-
122103## Native Projects
123104
124105This package uses native libraries. Create native Android and iOS projects (if not created already) by running:
You can’t perform that action at this time.
0 commit comments