sqlc-dev/sqlc-gen-typescript

Minor annoyance: an unused import is generated for pg

KMahoney opened this issue · 1 comments

Hi, thanks for this! It looks really useful.

I encountered a small issue with the 'pg' backend. This line is generated:

import { IPostgresInterval } from "postgres-interval";

If it is not used, it is a compiler error when noUnusedLocals is on.

If it is difficult to selectively include, maybe add a // @ts-ignore annotation?

Congrats on Issue #1!

If it is not used, it is a compiler error when noUnusedLocals is on.

That's good to know. I thought it would just be ignored.

If it is difficult to selectively include, maybe add a // @ts-ignore annotation?

It shouldn't be too hard to import only when it's required.