Skip to content

Commit

Permalink
Allow multiline sql
Browse files Browse the repository at this point in the history
I have not tested this (just made the intuitive change in github) but curious if it works / you are interested. This is intended as a proof-of-concept for adelsz/pgtyped#233
  • Loading branch information
rattrayalex authored Jun 22, 2021
1 parent de9dc91 commit f44e619
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/Utils/StringUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ export type MatchString<Candidate, Pattern extends string> =
MatchString<EatFirstChar<Candidate>, Pattern> extends true ? true :
false;

export type Trim<T> = T extends ` ${infer Rest}` ? Trim<Rest> : T;
export type Trim<T> =
T extends ` ${infer Rest}` ? Trim<Rest> :
T extends `\n${infer Rest}` ? Trim<Rest> :
T;


type Indents = {
Expand Down

0 comments on commit f44e619

Please sign in to comment.