Closed
Description
Bug report
- I confirm this is a bug with Supabase, not with my own application.
- I confirm I have searched the Docs, GitHub Discussions, and Discord.
Describe the bug
Generating TypeScript types for a Supabase project is resulting in unexpected unknown
properties. Specifically, any array type (e.g. text[]
) generates unknown
(instead of e.g. string[]
).
To Reproduce
- Define any type with
text[]
in Supabase:
CREATE TYPE example_type AS (
my_text_array text[]
);
- Generate types in client project:
npx supabase gen types typescript --schema public
Observe the unknown
property in the generated TypeScript types:
example_type: {
my_text_array: unknown
}
Expected behavior
I would expect a string[]
property in the generated types:
example_type: {
my_text_array: string[]
}
System information
- OS: MAC OS
- Version of supabase CLI: 1.60.2