pgtyped
pgtyped copied to clipboard
pgtyped doesn't see sql function call in SQL-in-TS mode
Hello.
If I export sql function using naming export everything works fine:
import { sql } from '@pgtyped/query'
const getSomething = sql`SELECT * FROM users`
But I can't use naming exports in pgtyped packages due to this problem, so I have to use this approach:
import pgtyped from '@pgtyped/query'
const getSomething = pgtyped.sql`SELECT * FROM users`
But in this case pgtyped doesn't generate typings.
@adelsz could you please fix it?
pgTyped now supports ESM.