@slonik/types 43.0.4 → 43.0.6
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/README.md +1 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -15
- package/dist/index.js.map +1 -1
- package/dist/types.d.ts +17 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +7 -1
- package/src/index.ts +8 -1
- package/src/types.ts +19 -0
package/README.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export
|
|
1
|
+
export { type ConnectionOptions, type Field, type PrimitiveValueExpression, type Query, type QueryResultRow, type SerializableValue, } from './types';
|
|
2
2
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,iBAAiB,EACtB,KAAK,KAAK,EACV,KAAK,wBAAwB,EAC7B,KAAK,KAAK,EACV,KAAK,cAAc,EACnB,KAAK,iBAAiB,GACvB,MAAM,SAAS,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -1,18 +1,3 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./types"), exports);
|
|
18
3
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}
|
package/dist/types.d.ts
CHANGED
|
@@ -8,4 +8,21 @@ export type QueryResultRow = Record<string, PrimitiveValueExpression>;
|
|
|
8
8
|
export type SerializableValue = SerializableValue[] | boolean | number | string | readonly SerializableValue[] | {
|
|
9
9
|
[key: string]: SerializableValue;
|
|
10
10
|
} | null | undefined;
|
|
11
|
+
/**
|
|
12
|
+
* @see https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-PARAMKEYWORDS
|
|
13
|
+
*/
|
|
14
|
+
export type ConnectionOptions = {
|
|
15
|
+
applicationName?: string;
|
|
16
|
+
databaseName?: string;
|
|
17
|
+
host?: string;
|
|
18
|
+
options?: string;
|
|
19
|
+
password?: string;
|
|
20
|
+
port?: number;
|
|
21
|
+
sslMode?: 'disable' | 'no-verify' | 'require';
|
|
22
|
+
username?: string;
|
|
23
|
+
};
|
|
24
|
+
export type Field = {
|
|
25
|
+
readonly dataTypeId: number;
|
|
26
|
+
readonly name: string;
|
|
27
|
+
};
|
|
11
28
|
//# sourceMappingURL=types.d.ts.map
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";AAAA,MAAM,MAAM,wBAAwB,GAChC,MAAM,GACN,MAAM,GACN,OAAO,GACP,MAAM,GACN,MAAM,GACN,SAAS,wBAAwB,EAAE,GACnC,IAAI,CAAC;AAET,MAAM,MAAM,KAAK,GAAG;IAClB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,MAAM,EAAE,SAAS,wBAAwB,EAAE,CAAC;CACtD,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,wBAAwB,CAAC,CAAC;AAEtE,MAAM,MAAM,iBAAiB,GACzB,iBAAiB,EAAE,GACnB,OAAO,GACP,MAAM,GACN,MAAM,GACN,SAAS,iBAAiB,EAAE,GAC5B;IACE,CAAC,GAAG,EAAE,MAAM,GAAG,iBAAiB,CAAC;CAClC,GACD,IAAI,GACJ,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";AAAA,MAAM,MAAM,wBAAwB,GAChC,MAAM,GACN,MAAM,GACN,OAAO,GACP,MAAM,GACN,MAAM,GACN,SAAS,wBAAwB,EAAE,GACnC,IAAI,CAAC;AAET,MAAM,MAAM,KAAK,GAAG;IAClB,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,MAAM,EAAE,SAAS,wBAAwB,EAAE,CAAC;CACtD,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,wBAAwB,CAAC,CAAC;AAEtE,MAAM,MAAM,iBAAiB,GACzB,iBAAiB,EAAE,GACnB,OAAO,GACP,MAAM,GACN,MAAM,GACN,SAAS,iBAAiB,EAAE,GAC5B;IACE,CAAC,GAAG,EAAE,MAAM,GAAG,iBAAiB,CAAC;CAClC,GACD,IAAI,GACJ,SAAS,CAAC;AAEd;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG;IAC9B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,SAAS,GAAG,WAAW,GAAG,SAAS,CAAC;IAC9C,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF,MAAM,MAAM,KAAK,GAAG;IAClB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACvB,CAAC"}
|
package/package.json
CHANGED
|
@@ -40,6 +40,12 @@
|
|
|
40
40
|
],
|
|
41
41
|
"license": "BSD-3-Clause",
|
|
42
42
|
"main": "./dist/index.js",
|
|
43
|
+
"exports": {
|
|
44
|
+
".": {
|
|
45
|
+
"require": "./dist/index.js",
|
|
46
|
+
"types": "./dist/index.d.ts"
|
|
47
|
+
}
|
|
48
|
+
},
|
|
43
49
|
"name": "@slonik/types",
|
|
44
50
|
"nyc": {
|
|
45
51
|
"all": true,
|
|
@@ -75,5 +81,5 @@
|
|
|
75
81
|
"test": "nyc ava --verbose --serial"
|
|
76
82
|
},
|
|
77
83
|
"types": "./dist/index.d.ts",
|
|
78
|
-
"version": "43.0.
|
|
84
|
+
"version": "43.0.6"
|
|
79
85
|
}
|
package/src/index.ts
CHANGED
package/src/types.ts
CHANGED
|
@@ -25,3 +25,22 @@ export type SerializableValue =
|
|
|
25
25
|
}
|
|
26
26
|
| null
|
|
27
27
|
| undefined;
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* @see https://www.postgresql.org/docs/current/libpq-connect.html#LIBPQ-PARAMKEYWORDS
|
|
31
|
+
*/
|
|
32
|
+
export type ConnectionOptions = {
|
|
33
|
+
applicationName?: string;
|
|
34
|
+
databaseName?: string;
|
|
35
|
+
host?: string;
|
|
36
|
+
options?: string;
|
|
37
|
+
password?: string;
|
|
38
|
+
port?: number;
|
|
39
|
+
sslMode?: 'disable' | 'no-verify' | 'require';
|
|
40
|
+
username?: string;
|
|
41
|
+
};
|
|
42
|
+
|
|
43
|
+
export type Field = {
|
|
44
|
+
readonly dataTypeId: number;
|
|
45
|
+
readonly name: string;
|
|
46
|
+
};
|