@pi-r/postgres 0.9.0 → 0.9.2
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/client/index.d.ts +10 -10
- package/client/pool.d.ts +8 -8
- package/package.json +5 -5
- package/types/index.d.ts +13 -13
package/client/index.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import type { IDb } from '@e-mc/types/lib';
|
|
2
|
-
|
|
3
|
-
import type { IDbSourceClient } from '@e-mc/db/types';
|
|
4
|
-
|
|
5
|
-
import type { PostgresCredential, PostgresDataSource } from '../types';
|
|
6
|
-
|
|
7
|
-
declare const Postgres: IDbSourceClient<PostgresDataSource> & {
|
|
8
|
-
setAuthentication(this: IDb, credential: PostgresCredential): void;
|
|
9
|
-
};
|
|
10
|
-
|
|
1
|
+
import type { IDb } from '@e-mc/types/lib';
|
|
2
|
+
|
|
3
|
+
import type { IDbSourceClient } from '@e-mc/db/types';
|
|
4
|
+
|
|
5
|
+
import type { PostgresCredential, PostgresDataSource } from '../types';
|
|
6
|
+
|
|
7
|
+
declare const Postgres: IDbSourceClient<PostgresDataSource> & {
|
|
8
|
+
setAuthentication(this: IDb, credential: PostgresCredential): void;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
11
|
export = Postgres;
|
package/client/pool.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import type { DbPoolConstructor } from '@e-mc/types/lib/db';
|
|
2
|
-
|
|
3
|
-
import type { DbPoolCredential, PostgresDataSource } from '../types';
|
|
4
|
-
|
|
5
|
-
import type { Pool, PoolClient } from 'pg';
|
|
6
|
-
|
|
7
|
-
declare const PostgresPool: DbPoolConstructor<PostgresDataSource, Pool, PoolClient, DbPoolCredential>;
|
|
8
|
-
|
|
1
|
+
import type { DbPoolConstructor } from '@e-mc/types/lib/db';
|
|
2
|
+
|
|
3
|
+
import type { DbPoolCredential, PostgresDataSource } from '../types';
|
|
4
|
+
|
|
5
|
+
import type { Pool, PoolClient } from 'pg';
|
|
6
|
+
|
|
7
|
+
declare const PostgresPool: DbPoolConstructor<PostgresDataSource, Pool, PoolClient, DbPoolCredential>;
|
|
8
|
+
|
|
9
9
|
export = PostgresPool;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pi-r/postgres",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.2",
|
|
4
4
|
"description": "PostgreSQL client driver for E-mc.",
|
|
5
5
|
"main": "client/index.js",
|
|
6
6
|
"types": "client/index.d.ts",
|
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
"license": "MIT",
|
|
21
21
|
"homepage": "https://github.com/anpham6/pi-r#readme",
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@e-mc/db": "^0.11.
|
|
24
|
-
"@e-mc/types": "^0.11.
|
|
25
|
-
"pg": "^8.13.
|
|
23
|
+
"@e-mc/db": "^0.11.2",
|
|
24
|
+
"@e-mc/types": "^0.11.2",
|
|
25
|
+
"pg": "^8.13.3",
|
|
26
26
|
"pg-connection-string": "^2.7.0",
|
|
27
|
-
"pg-query-stream": "^4.7.
|
|
27
|
+
"pg-query-stream": "^4.7.3"
|
|
28
28
|
}
|
|
29
29
|
}
|
package/types/index.d.ts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import type { DbDataSource } from '@e-mc/types/lib/squared';
|
|
2
|
-
|
|
3
|
-
import type { IdentifierAction } from '@e-mc/types/lib/core';
|
|
4
|
-
import type { ExecuteAction, ServerAuth } from '@e-mc/types/lib/db';
|
|
5
|
-
|
|
6
|
-
// @ts-ignore
|
|
7
|
-
import type { PoolConfig, QueryArrayConfig } from 'pg';
|
|
8
|
-
|
|
9
|
-
export interface PostgresDataSource<T = unknown[]> extends DbDataSource<string | QueryArrayConfig, unknown, unknown, PostgresCredential, string>, ExecuteAction<T> {
|
|
10
|
-
source: "postgres";
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export interface PostgresCredential extends Omit<ServerAuth, "password">, PoolConfig {}
|
|
1
|
+
import type { DbDataSource } from '@e-mc/types/lib/squared';
|
|
2
|
+
|
|
3
|
+
import type { IdentifierAction } from '@e-mc/types/lib/core';
|
|
4
|
+
import type { ExecuteAction, ServerAuth } from '@e-mc/types/lib/db';
|
|
5
|
+
|
|
6
|
+
// @ts-ignore
|
|
7
|
+
import type { PoolConfig, QueryArrayConfig } from 'pg';
|
|
8
|
+
|
|
9
|
+
export interface PostgresDataSource<T = unknown[]> extends DbDataSource<string | QueryArrayConfig, unknown, unknown, PostgresCredential, string>, ExecuteAction<T> {
|
|
10
|
+
source: "postgres";
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface PostgresCredential extends Omit<ServerAuth, "password">, PoolConfig {}
|
|
14
14
|
export type DbPoolCredential = PoolConfig & IdentifierAction;
|