Closed gBasil closed 1 year ago
Didn´t even notice i missed json.
I´d rather type json as any
or
type Json = boolean | string | number | Json[] | { [K: string]: Json };
depending on how strict the types should be. It seems like you can even use Date
and URL
objects in json when using create
or update
. So i´d rather go with any for json
type and unknown
for unknown types.
Added support in version 0.0.4
, thanks for reporting the issue
The types for JSON values could potentially be defined on TypedPocketBase
when initializing the type.
The
json
field type currently isn't supported and crashes the codegen. It would be nice to have even untyped support and marking the field (and potentially other currently untyped fields) asunknown
.