@relq/orm 0.1.4 → 0.1.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/dist/cjs/addon/cursor.cjs +1 -1407
- package/dist/cjs/addon/mysql2.cjs +0 -1
- package/dist/cjs/addon/pg.cjs +1 -2
- package/dist/cjs/core/relq-client.cjs +58 -67
- package/dist/esm/addon/cursor.js +1 -1441
- package/dist/esm/addon/mysql2.js +2 -9
- package/dist/esm/addon/pg.js +2 -4
- package/dist/esm/core/relq-client.js +43 -41
- package/package.json +2 -1
package/dist/esm/addon/mysql2.js
CHANGED
|
@@ -21120,13 +21120,6 @@ var require_promise = __commonJS((exports) => {
|
|
|
21120
21120
|
|
|
21121
21121
|
// src/orm/mysql/utils/addon/mysql/mysql2.ts
|
|
21122
21122
|
var exports_mysql2 = {};
|
|
21123
|
-
__export(exports_mysql2, {
|
|
21124
|
-
default: () => import_promise.default
|
|
21125
|
-
});
|
|
21123
|
+
__export(exports_mysql2, {});
|
|
21126
21124
|
__reExport(exports_mysql2, __toESM(require_promise(), 1));
|
|
21127
|
-
|
|
21128
|
-
var export_default = import_promise.default;
|
|
21129
|
-
|
|
21130
|
-
export {
|
|
21131
|
-
export_default as default
|
|
21132
|
-
};
|
|
21125
|
+
export {};
|
package/dist/esm/addon/pg.js
CHANGED
|
@@ -144,8 +144,8 @@ var require_arrayParser = __commonJS((exports, module) => {
|
|
|
144
144
|
|
|
145
145
|
// node_modules/postgres-date/index.js
|
|
146
146
|
var require_postgres_date = __commonJS((exports, module) => {
|
|
147
|
-
var DATE_TIME = /(\d{1
|
|
148
|
-
var DATE = /^(\d{1
|
|
147
|
+
var DATE_TIME = /(\d{1 })-(\d{2})-(\d{2}) (\d{2}):(\d{2}):(\d{2})(\.\d{1 })?.*?( BC)?$/;
|
|
148
|
+
var DATE = /^(\d{1 })-(\d{2})-(\d{2})( BC)?$/;
|
|
149
149
|
var TIME_ZONE = /([Z+-])(\d{2})?:?(\d{2})?:?(\d{2})?/;
|
|
150
150
|
var INFINITY = /^-?infinity$/;
|
|
151
151
|
module.exports = function parseDate(isoDate) {
|
|
@@ -4915,13 +4915,11 @@ var escapeLiteral = import_lib.default.escapeLiteral;
|
|
|
4915
4915
|
var Result = import_lib.default.Result;
|
|
4916
4916
|
var TypeOverrides = import_lib.default.TypeOverrides;
|
|
4917
4917
|
var defaults = import_lib.default.defaults;
|
|
4918
|
-
var esm_default = import_lib.default;
|
|
4919
4918
|
export {
|
|
4920
4919
|
types,
|
|
4921
4920
|
escapeLiteral,
|
|
4922
4921
|
escapeIdentifier,
|
|
4923
4922
|
defaults,
|
|
4924
|
-
esm_default as default,
|
|
4925
4923
|
TypeOverrides,
|
|
4926
4924
|
Result,
|
|
4927
4925
|
Query,
|
|
@@ -1,68 +1,70 @@
|
|
|
1
|
-
import { RelqPostgres } from "../pg/clients/pg-client/index.js";
|
|
2
|
-
import { RelqNile } from "../pg/clients/nile-client/index.js";
|
|
3
|
-
import { RelqDsql } from "../pg/clients/dsql-client/index.js";
|
|
4
|
-
import { RelqCockroachDB } from "../pg/clients/cockroachdb-client/index.js";
|
|
5
|
-
import { RelqSupabase } from "../pg/clients/supabase-client/index.js";
|
|
6
|
-
import { RelqNeon } from "../pg/clients/neon-client/index.js";
|
|
7
|
-
import { RelqAlloyDB } from "../pg/clients/alloydb-client/index.js";
|
|
8
|
-
import { RelqAurora } from "../pg/clients/aurora-client/index.js";
|
|
9
|
-
import { RelqYugabyteDB } from "../pg/clients/yugabytedb-client/index.js";
|
|
10
|
-
import { RelqCitus } from "../pg/clients/citus-client/index.js";
|
|
11
|
-
import { RelqTimescale } from "../pg/clients/timescale-client/index.js";
|
|
12
|
-
import { RelqMysql } from "../mysql/clients/mysql-client/index.js";
|
|
13
|
-
import { RelqMariaDB } from "../mysql/clients/mariadb-client/index.js";
|
|
14
|
-
import { RelqPlanetScale } from "../mysql/clients/planetscale-client/index.js";
|
|
15
1
|
import { RelqConfigError } from "../shared/errors/relq-errors.js";
|
|
16
2
|
const SUPPORTED_DIALECTS = 'postgres, nile, cockroachdb, awsdsql, supabase, neon, alloydb, aurora, yugabytedb, citus, timescale, mysql, mariadb, planetscale';
|
|
17
3
|
class RelqImpl {
|
|
18
4
|
constructor(schema, dialect, options) {
|
|
19
5
|
const opts = options ?? {};
|
|
20
6
|
switch (dialect) {
|
|
21
|
-
case 'postgres':
|
|
7
|
+
case 'postgres': {
|
|
8
|
+
const { RelqPostgres } = require('../pg/clients/pg-client');
|
|
22
9
|
return new RelqPostgres(schema, { ...opts, dialect: 'postgres' });
|
|
23
|
-
|
|
10
|
+
}
|
|
11
|
+
case 'nile': {
|
|
12
|
+
const { RelqNile } = require('../pg/clients/nile-client');
|
|
24
13
|
return new RelqNile(schema, { ...opts, dialect: 'nile' });
|
|
25
|
-
|
|
14
|
+
}
|
|
15
|
+
case 'cockroachdb': {
|
|
16
|
+
const { RelqCockroachDB } = require('../pg/clients/cockroachdb-client');
|
|
26
17
|
return new RelqCockroachDB(schema, { ...opts, dialect: 'cockroachdb' });
|
|
27
|
-
|
|
18
|
+
}
|
|
19
|
+
case 'awsdsql': {
|
|
20
|
+
const { RelqDsql } = require('../pg/clients/dsql-client');
|
|
28
21
|
return new RelqDsql(schema, { ...opts, dialect: 'awsdsql' });
|
|
29
|
-
|
|
22
|
+
}
|
|
23
|
+
case 'supabase': {
|
|
24
|
+
const { RelqSupabase } = require('../pg/clients/supabase-client');
|
|
30
25
|
return new RelqSupabase(schema, { ...opts, dialect: 'supabase' });
|
|
31
|
-
|
|
26
|
+
}
|
|
27
|
+
case 'neon': {
|
|
28
|
+
const { RelqNeon } = require('../pg/clients/neon-client');
|
|
32
29
|
return new RelqNeon(schema, { ...opts, dialect: 'neon' });
|
|
33
|
-
|
|
30
|
+
}
|
|
31
|
+
case 'alloydb': {
|
|
32
|
+
const { RelqAlloyDB } = require('../pg/clients/alloydb-client');
|
|
34
33
|
return new RelqAlloyDB(schema, { ...opts, dialect: 'alloydb' });
|
|
35
|
-
|
|
34
|
+
}
|
|
35
|
+
case 'aurora': {
|
|
36
|
+
const { RelqAurora } = require('../pg/clients/aurora-client');
|
|
36
37
|
return new RelqAurora(schema, { ...opts, dialect: 'aurora' });
|
|
37
|
-
|
|
38
|
+
}
|
|
39
|
+
case 'yugabytedb': {
|
|
40
|
+
const { RelqYugabyteDB } = require('../pg/clients/yugabytedb-client');
|
|
38
41
|
return new RelqYugabyteDB(schema, { ...opts, dialect: 'yugabytedb' });
|
|
39
|
-
|
|
42
|
+
}
|
|
43
|
+
case 'citus': {
|
|
44
|
+
const { RelqCitus } = require('../pg/clients/citus-client');
|
|
40
45
|
return new RelqCitus(schema, { ...opts, dialect: 'citus' });
|
|
41
|
-
|
|
46
|
+
}
|
|
47
|
+
case 'timescale': {
|
|
48
|
+
const { RelqTimescale } = require('../pg/clients/timescale-client');
|
|
42
49
|
return new RelqTimescale(schema, { ...opts, dialect: 'timescale' });
|
|
43
|
-
|
|
50
|
+
}
|
|
51
|
+
case 'mysql': {
|
|
52
|
+
const { RelqMysql } = require('../mysql/clients/mysql-client');
|
|
44
53
|
return new RelqMysql(schema, { ...opts, dialect: 'mysql' });
|
|
45
|
-
|
|
54
|
+
}
|
|
55
|
+
case 'mariadb': {
|
|
56
|
+
const { RelqMariaDB } = require('../mysql/clients/mariadb-client');
|
|
46
57
|
return new RelqMariaDB(schema, { ...opts, dialect: 'mariadb' });
|
|
47
|
-
|
|
58
|
+
}
|
|
59
|
+
case 'planetscale': {
|
|
60
|
+
const { RelqPlanetScale } = require('../mysql/clients/planetscale-client');
|
|
48
61
|
return new RelqPlanetScale(schema, { ...opts, dialect: 'planetscale' });
|
|
62
|
+
}
|
|
49
63
|
default:
|
|
50
|
-
throw new RelqConfigError(`Unknown dialect: "${dialect}".
|
|
51
|
-
`Supported dialects: ${SUPPORTED_DIALECTS}, mysql, mariadb, planetscale`, { field: 'dialect', value: dialect });
|
|
64
|
+
throw new RelqConfigError(`Unknown dialect: "${dialect}". Supported: ${SUPPORTED_DIALECTS}`, { field: 'dialect', value: dialect });
|
|
52
65
|
}
|
|
53
66
|
}
|
|
54
67
|
}
|
|
55
68
|
export const Relq = RelqImpl;
|
|
56
|
-
export { RelqPostgres } from "../pg/clients/pg-client/index.js";
|
|
57
|
-
export { RelqNile } from "../pg/clients/nile-client/index.js";
|
|
58
|
-
export { RelqDsql } from "../pg/clients/dsql-client/index.js";
|
|
59
|
-
export { RelqCockroachDB } from "../pg/clients/cockroachdb-client/index.js";
|
|
60
|
-
export { RelqSupabase } from "../pg/clients/supabase-client/index.js";
|
|
61
|
-
export { RelqNeon } from "../pg/clients/neon-client/index.js";
|
|
62
|
-
export { RelqAlloyDB } from "../pg/clients/alloydb-client/index.js";
|
|
63
|
-
export { RelqAurora } from "../pg/clients/aurora-client/index.js";
|
|
64
|
-
export { RelqYugabyteDB } from "../pg/clients/yugabytedb-client/index.js";
|
|
65
|
-
export { RelqCitus } from "../pg/clients/citus-client/index.js";
|
|
66
|
-
export { RelqTimescale } from "../pg/clients/timescale-client/index.js";
|
|
67
69
|
export { RelqBase } from "./relq-base.js";
|
|
68
70
|
export default Relq;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@relq/orm",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
4
|
"description": "The runtime engine for Relq — type-safe PostgreSQL ORM for TypeScript",
|
|
5
5
|
"author": "Olajide Mathew O. <olajide.mathew@yuniq.solutions>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -43,6 +43,7 @@
|
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@aws-sdk/dsql-signer": "^3.1019.0"
|
|
45
45
|
},
|
|
46
|
+
"sideEffects": false,
|
|
46
47
|
"peerDependencies": {
|
|
47
48
|
"@relq/kit": ">=0.1.0"
|
|
48
49
|
},
|