pgsql-deparser 13.18.0 → 13.19.0
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/LICENSE +21 -0
- package/deparser/deparser.d.ts +302 -0
- package/deparser/deparser.js +10451 -0
- package/deparser/index.d.ts +9 -0
- package/deparser/index.js +17 -0
- package/deparser/utils/list-utils.d.ts +8 -0
- package/deparser/utils/list-utils.js +30 -0
- package/deparser/utils/quote-utils.d.ts +24 -0
- package/deparser/utils/quote-utils.js +89 -0
- package/deparser/utils/sql-formatter.d.ts +16 -0
- package/deparser/utils/sql-formatter.js +40 -0
- package/deparser/visitors/base.d.ts +68 -0
- package/deparser/visitors/base.js +122 -0
- package/{src/deparser/deparser.ts → esm/deparser/deparser.js} +589 -616
- package/{src/deparser/index.ts → esm/deparser/index.js} +3 -4
- package/{src/deparser/utils/list-utils.ts → esm/deparser/utils/list-utils.js} +2 -3
- package/{src/deparser/utils/quote-utils.ts → esm/deparser/utils/quote-utils.js} +6 -7
- package/{src/deparser/utils/sql-formatter.ts → esm/deparser/utils/sql-formatter.js} +10 -11
- package/{src/deparser/visitors/base.ts → esm/deparser/visitors/base.js} +34 -62
- package/esm/index.js +15 -0
- package/{src/v13-to-v14.ts → esm/v13-to-v14.js} +472 -609
- package/{src/v13-to-v17-direct.ts → esm/v13-to-v17-direct.js} +11 -12
- package/{src/v14-to-v15.ts → esm/v14-to-v15.js} +261 -662
- package/{src/v15-to-v16.ts → esm/v15-to-v16.js} +814 -1229
- package/esm/v16-to-v17.js +1488 -0
- package/index.d.ts +9 -0
- package/index.js +19 -0
- package/package.json +1 -1
- package/v13-to-v14.d.ts +253 -0
- package/v13-to-v14.js +2754 -0
- package/v13-to-v17-direct.d.ts +24 -0
- package/v13-to-v17-direct.js +82 -0
- package/v14-to-v15.d.ts +616 -0
- package/v14-to-v15.js +1227 -0
- package/v15-to-v16.d.ts +633 -0
- package/v15-to-v16.js +2944 -0
- package/v16-to-v17.d.ts +638 -0
- package/v16-to-v17.js +1492 -0
- package/src/index.ts +0 -27
- package/src/v16-to-v17.ts +0 -1897
- package/tsconfig.esm.json +0 -8
- package/tsconfig.json +0 -26
package/src/index.ts
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Deparser for PostgreSQL version 13
|
|
3
|
-
* Auto-generated by generate-version-deparsers.ts
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
import { Node, ParseResult } from '@pgsql/types';
|
|
7
|
-
import {
|
|
8
|
-
deparse as deparse17,
|
|
9
|
-
deparseSync as deparseSync17,
|
|
10
|
-
DeparserOptions
|
|
11
|
-
} from './deparser';
|
|
12
|
-
import { PG13ToPG17Transformer } from './v13-to-v17-direct';
|
|
13
|
-
|
|
14
|
-
const tx = new PG13ToPG17Transformer();
|
|
15
|
-
|
|
16
|
-
export async function deparse(query: Node | Node[] | ParseResult, opts?: DeparserOptions): Promise<string> {
|
|
17
|
-
const ast17 = tx.transform(query);
|
|
18
|
-
return await deparse17(ast17, opts);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
export function deparseSync(query: Node | Node[] | ParseResult, opts?: DeparserOptions): string {
|
|
22
|
-
const ast17 = tx.transform(query);
|
|
23
|
-
return deparseSync17(ast17, opts);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
// Re-export DeparserOptions for convenience
|
|
27
|
-
export { DeparserOptions } from './deparser';
|