File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,8 @@ import { DataLayerProvider } from './core/interfaces';
55interface DBEnv {
66 COUCHDB_SERVER_URL : string ; // URL of CouchDB server
77 COUCHDB_SERVER_PROTOCOL : string ; // Protocol of CouchDB server (http or https)
8+ COUCHDB_USERNAME ?: string ;
9+ COUCHDB_PASSWORD ?: string ;
810}
911
1012export const ENV : DBEnv = {
@@ -20,6 +22,8 @@ export interface DataLayerConfig {
2022 localStoragePrefix ?: string ; // Prefix for IndexedDB storage names
2123 COUCHDB_SERVER_URL ?: string ;
2224 COUCHDB_SERVER_PROTOCOL ?: string ;
25+ COUCHDB_USERNAME ?: string ;
26+ COUCHDB_PASSWORD ?: string ;
2327 } ;
2428}
2529
@@ -41,6 +45,8 @@ export async function initializeDataLayer(config: DataLayerConfig): Promise<Data
4145 }
4246 ENV . COUCHDB_SERVER_PROTOCOL = config . options . COUCHDB_SERVER_PROTOCOL ;
4347 ENV . COUCHDB_SERVER_URL = config . options . COUCHDB_SERVER_URL ;
48+ ENV . COUCHDB_USERNAME = config . options . COUCHDB_USERNAME ;
49+ ENV . COUCHDB_PASSWORD = config . options . COUCHDB_PASSWORD ;
4450
4551 // Dynamic import to avoid loading both implementations when only one is needed
4652 const { PouchDataLayerProvider } = await import ( './impl/pouch/PouchDataLayerProvider' ) ;
You can’t perform that action at this time.
0 commit comments