adelsz / pgtyped

pgTyped - Typesafe SQL in TypeScript
https://pgtyped.dev
MIT License
2.97k stars 97 forks source link

Separate name and definition of union types to prevent Array naming issues #521

Closed leifniem closed 1 year ago

leifniem commented 1 year ago

The current version produces the following code

export type number | stringArray = (number | string)[];

If i did not miss anything vital this should produce the correct type names.

leifniem commented 1 year ago

I just noticed a place where this might not be correct, but that might also be due to me casting a parameter in a wrong way. I'll let you know once i found out.

EDIT: Pretty sure it was an error on my end.

leifniem commented 1 year ago

Sorry, code from my project appeared here because i used my fork as a submodule, i will clean it up when i get the time

leifniem commented 1 year ago

@adelsz removed everything i accidentally had in the repo. it's down to one file now :)

KhaledElmorsy commented 1 year ago

Hope this gets merged soon.

leifniem commented 1 year ago

Since the dev is located in Ukraine i totally understand if it's still open for a while.

adelsz commented 1 year ago

Thanks @leifniem!