rawsql-ts
Version:
High-performance SQL parser and AST analyzer written in TypeScript. Provides fast parsing and advanced transformation capabilities.
12 lines (11 loc) • 712 B
TypeScript
import { SelectQuery, SimpleSelectQuery } from "../models/SelectQuery";
import { ValueComponent } from "../models/ValueComponent";
import { SqlFormatterOptions } from "./SqlFormatter";
export type FormattableSqlComponent = SelectQuery | SimpleSelectQuery | ValueComponent;
export type SqlComponentFormatter = (component: FormattableSqlComponent) => string;
export interface SqlComponentFormatOptions {
formatter?: SqlComponentFormatter;
formatOptions?: SqlFormatterOptions;
}
export declare const formatSqlComponent: (component: FormattableSqlComponent, options?: SqlComponentFormatOptions) => string;
export declare const hasSqlComponentFormatOverride: (options?: SqlComponentFormatOptions) => boolean;