@xeno-js/core 0.1.7 → 0.1.9
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.
- package/dist/index.cjs +36 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +39 -1
- package/dist/index.d.ts +39 -1
- package/dist/index.js +36 -0
- package/dist/index.js.map +1 -1
- package/package.json +160 -160
package/dist/index.cjs
CHANGED
|
@@ -4404,6 +4404,8 @@ var init_middleware_module = __esm({
|
|
|
4404
4404
|
}
|
|
4405
4405
|
if (import_shared73.Guards.isDefined(opts.csrf)) {
|
|
4406
4406
|
const csrf = opts.csrf;
|
|
4407
|
+
const { EdgeCryptoService: EdgeCryptoService2 } = await Promise.resolve().then(() => (init_services(), services_exports));
|
|
4408
|
+
container.addSingleton("CRYPTO_SERVICE", () => new EdgeCryptoService2());
|
|
4407
4409
|
const { CsrfTokenService: CsrfTokenService2 } = await Promise.resolve().then(() => (init_services(), services_exports));
|
|
4408
4410
|
container.addSingleton("CSRF_TOKEN_SERVICE", (c) => {
|
|
4409
4411
|
return new CsrfTokenService2(csrf.secret, c.resolve("CRYPTO_SERVICE"));
|
|
@@ -4485,7 +4487,9 @@ __export(index_exports, {
|
|
|
4485
4487
|
BaseAuthorizationStrategy: () => BaseAuthorizationStrategy,
|
|
4486
4488
|
BaseController: () => BaseController,
|
|
4487
4489
|
BaseHandler: () => BaseHandler,
|
|
4490
|
+
BasePostgresSqlDataSource: () => BasePostgresSqlDataSource,
|
|
4488
4491
|
BaseQuery: () => import_shared80.Query,
|
|
4492
|
+
BaseSqliteSqlDataSource: () => BaseSqliteSqlDataSource,
|
|
4489
4493
|
ContainerUtils: () => ContainerUtils,
|
|
4490
4494
|
ReadDao: () => ReadDao,
|
|
4491
4495
|
Repository: () => Repository,
|
|
@@ -5258,6 +5262,36 @@ init_cache();
|
|
|
5258
5262
|
// src/infrastructure/context/index.ts
|
|
5259
5263
|
init_request_context();
|
|
5260
5264
|
|
|
5265
|
+
// src/infrastructure/datasources/base-postgressql.datasource.ts
|
|
5266
|
+
var BasePostgresSqlDataSource = class {
|
|
5267
|
+
constructor(_db) {
|
|
5268
|
+
this._db = _db;
|
|
5269
|
+
}
|
|
5270
|
+
_db;
|
|
5271
|
+
/**
|
|
5272
|
+
* @description Returns the database connection.
|
|
5273
|
+
* @returns {NodePgDatabase<TSchema>} The database connection.
|
|
5274
|
+
*/
|
|
5275
|
+
get db() {
|
|
5276
|
+
return this._db;
|
|
5277
|
+
}
|
|
5278
|
+
};
|
|
5279
|
+
|
|
5280
|
+
// src/infrastructure/datasources/base-sqllite.datasource.ts
|
|
5281
|
+
var BaseSqliteSqlDataSource = class {
|
|
5282
|
+
constructor(_db) {
|
|
5283
|
+
this._db = _db;
|
|
5284
|
+
}
|
|
5285
|
+
_db;
|
|
5286
|
+
/**
|
|
5287
|
+
* @description Returns the SQLite database connection.
|
|
5288
|
+
* @returns {LibSQLDatabase<TSchema>} The database connection.
|
|
5289
|
+
*/
|
|
5290
|
+
get db() {
|
|
5291
|
+
return this._db;
|
|
5292
|
+
}
|
|
5293
|
+
};
|
|
5294
|
+
|
|
5261
5295
|
// src/infrastructure/datasources/remote.datasource.ts
|
|
5262
5296
|
var import_shared75 = require("@xeno-js/shared");
|
|
5263
5297
|
|
|
@@ -5399,7 +5433,9 @@ var import_shared80 = require("@xeno-js/shared");
|
|
|
5399
5433
|
BaseAuthorizationStrategy,
|
|
5400
5434
|
BaseController,
|
|
5401
5435
|
BaseHandler,
|
|
5436
|
+
BasePostgresSqlDataSource,
|
|
5402
5437
|
BaseQuery,
|
|
5438
|
+
BaseSqliteSqlDataSource,
|
|
5403
5439
|
ContainerUtils,
|
|
5404
5440
|
ReadDao,
|
|
5405
5441
|
Repository,
|