rads-db 0.1.47 → 0.1.48
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.d.ts +1 -30
- package/drivers/azureCosmos.d.ts +8 -0
- package/drivers/memory.d.ts +3 -1
- package/drivers/restApi.d.ts +9 -0
- package/fileUploadDrivers/azureStorageBlob.d.ts +5 -0
- package/fileUploadDrivers/cloudinary.d.ts +3 -1
- package/fileUploadDrivers/memory.d.ts +3 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { CosmosClientOptions } from '@azure/cosmos';
|
|
2
1
|
import { EntityMeta, RadsDb } from '_rads-db';
|
|
3
2
|
export { RadsDb } from '_rads-db';
|
|
4
3
|
|
|
@@ -211,15 +210,6 @@ interface PutEffect {
|
|
|
211
210
|
doc: any;
|
|
212
211
|
}[], beforePutResult: any) => MaybePromise<any>;
|
|
213
212
|
}
|
|
214
|
-
interface RestDriverOptions {
|
|
215
|
-
/** @default '/api' */
|
|
216
|
-
baseUrl?: string;
|
|
217
|
-
fetch?: (url: string, options?: {
|
|
218
|
-
body?: any;
|
|
219
|
-
headers?: any;
|
|
220
|
-
method?: string;
|
|
221
|
-
}) => any;
|
|
222
|
-
}
|
|
223
213
|
interface RestFileUploadDriverOptions {
|
|
224
214
|
/** @default '/api' */
|
|
225
215
|
baseUrl?: string;
|
|
@@ -229,25 +219,6 @@ interface RestFileUploadDriverOptions {
|
|
|
229
219
|
method?: string;
|
|
230
220
|
}) => any;
|
|
231
221
|
}
|
|
232
|
-
interface MemoryDriverOptions {
|
|
233
|
-
}
|
|
234
|
-
interface MemoryFileUploadDriverOptions {
|
|
235
|
-
}
|
|
236
|
-
interface AzureStorageBlobUploadDriverOptions {
|
|
237
|
-
connectionString: string;
|
|
238
|
-
defaultContainer?: string;
|
|
239
|
-
fileNamePrefix?: string;
|
|
240
|
-
}
|
|
241
|
-
interface AzureCosmosDriverOptions {
|
|
242
|
-
endpoint: string;
|
|
243
|
-
accountKey?: string;
|
|
244
|
-
databaseName?: string;
|
|
245
|
-
containerName?: string;
|
|
246
|
-
options?: Omit<CosmosClientOptions, 'key' | 'endpoint'>;
|
|
247
|
-
}
|
|
248
|
-
type DriverOptions = (RestDriverOptions | MemoryDriverOptions | AzureCosmosDriverOptions) & {
|
|
249
|
-
log?: RadsRequestContext['log'];
|
|
250
|
-
};
|
|
251
222
|
type GenerateClientOptions = Partial<GenerateClientNormalizedOptions>;
|
|
252
223
|
interface GenerateClientNormalizedOptions {
|
|
253
224
|
entitiesDir: string;
|
|
@@ -266,4 +237,4 @@ declare function computed(meta?: ComputedDecoratorArgs): (a: any, b?: ClassField
|
|
|
266
237
|
declare function createRads(args?: CreateRadsArgs): RadsDb;
|
|
267
238
|
declare function getRestRoutes(db: RadsDb, prefix?: string): Record<string, Record<string, Function>>;
|
|
268
239
|
|
|
269
|
-
export {
|
|
240
|
+
export { Change, ComputedContext, ComputedDecoratorArgs, CreateRadsArgs, DeepPartial, DeepPartialNullable, Driver, DriverConstructor, EntityDecoratorArgs, EntityMethods, FieldDecoratorArgs, FieldDefinition, FileUploadArgs, FileUploadDriver, GenerateClientNormalizedOptions, GenerateClientOptions, GetAggArgs, GetAggArgsAgg, GetAggArgsAny, GetAggResponse, GetArgs, GetArgsAny, GetArgsInclude, GetManyArgs, GetManyArgsAny, GetManyResponse, GetResponse, GetResponseInclude, GetResponseIncludeSelect, GetResponseNoInclude, MinimalDriver, PutArgs, PutEffect, RadsRequestContext, Relation, RestFileUploadDriverOptions, Schema, SchemaValidators, TypeDefinition, UiDecoratorArgs, UiFieldDecoratorArgs, ValidateEntityDecoratorArgs, ValidateFieldDecoratorArgs, ValidateStringDecoratorArgs, computed, createRads, entity, field, getRestRoutes, precomputed, ui, validate };
|
package/drivers/azureCosmos.d.ts
CHANGED
|
@@ -1,2 +1,10 @@
|
|
|
1
|
+
import type { CosmosClientOptions } from '@azure/cosmos';
|
|
2
|
+
interface AzureCosmosDriverOptions {
|
|
3
|
+
endpoint: string;
|
|
4
|
+
accountKey?: string;
|
|
5
|
+
databaseName?: string;
|
|
6
|
+
containerName?: string;
|
|
7
|
+
options?: Omit<CosmosClientOptions, 'key' | 'endpoint'>;
|
|
8
|
+
}
|
|
1
9
|
declare const _default: (options: AzureCosmosDriverOptions) => (schema: Schema, entity: string) => MinimalDriver;
|
|
2
10
|
export default _default;
|
package/drivers/memory.d.ts
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { GetAggArgsAny, GetManyArgsAny } from '@/typesClientEngine';
|
|
2
|
-
|
|
2
|
+
interface MemoryDriverOptions {
|
|
3
|
+
}
|
|
4
|
+
declare const _default: (options?: MemoryDriverOptions) => (schema: Schema, entity: string) => MinimalDriver;
|
|
3
5
|
export default _default;
|
|
4
6
|
export declare function getAggFromArray(array: any[], args: GetAggArgsAny): Record<string, any>;
|
|
5
7
|
export declare function queryArray(array: any[], args: GetManyArgsAny): {
|
package/drivers/restApi.d.ts
CHANGED
|
@@ -1,2 +1,11 @@
|
|
|
1
|
+
interface RestDriverOptions {
|
|
2
|
+
/** @default '/api' */
|
|
3
|
+
baseUrl?: string;
|
|
4
|
+
fetch?: (url: string, options?: {
|
|
5
|
+
body?: any;
|
|
6
|
+
headers?: any;
|
|
7
|
+
method?: string;
|
|
8
|
+
}) => any;
|
|
9
|
+
}
|
|
1
10
|
declare const _default: (options: RestDriverOptions) => (schema: Schema, entity: string) => MinimalDriver;
|
|
2
11
|
export default _default;
|