adelsz / pgtyped

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

fix: generate POSIX paths in typesOverrides imports #533

Closed lucas-gregoire closed 1 year ago

lucas-gregoire commented 1 year ago

Describe the bug

Generated imports for typesOverrides contain backslashes instead of slashes on Windows.

image

Relates to https://github.com/adelsz/pgtyped/issues/519

Expected behavior

Backslashes are invalid in TypeScript imports, so I expect it to generate the same import (with slashes) on both Unix systems and Windows.

Test case

lucas-gregoire commented 1 year ago

Hey @adelsz, do you think you could review and merge this PR ?