Skip to content

Commit

Permalink
fix: export IntrospectionResult type
Browse files Browse the repository at this point in the history
  • Loading branch information
retro committed Apr 7, 2024
1 parent 0d6b615 commit 635b14d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/lib/query-builder.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import {
AnyQuery,
AnyQueryFilter,
IntrospectionResult,
MemberFormat,
MemberNameToType,
MemberType,
Expand Down Expand Up @@ -153,7 +154,7 @@ export class QueryBuilder<
return result;
}

introspect(query: AnyQuery) {
introspect(query: AnyQuery): IntrospectionResult {
const queryDimensions = query.dimensions ?? [];
const queryMetrics = query.metrics ?? [];

Expand Down
11 changes: 11 additions & 0 deletions src/lib/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,3 +133,14 @@ export type InferSqlQueryResultType<
export type QueryMemberName<T> = T extends string[] ? T[number] : never;

export type AvailableDialects = "postgresql";

export type IntrospectionResult = Record<
string,
{
memberType: "dimension" | "metric";
path: string;
format?: MemberFormat | undefined;
type: MemberType;
description?: string | undefined;
}
>;

0 comments on commit 635b14d

Please sign in to comment.