-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
I'm using zod-geojson as detailed in the readme:
const schema = GeoJSONSchema.parse({
type: 'Feature',
geometry: {
type: 'Point',
coordinates: [0, 0],
},
properties: {
name: 'Null Island',
},
})
But for some reason, schema is typed as any
. It's also worth noting that I can call GeoJSONSchema.anything() without getting any type errors. However, GeoJSONSchema appears to be typed correctly (i.e. it isn't any
).
Is this a known issue? I anticipated that GeoJSONSchema.parse() would automatically type narrow the same way Zod does.
Thanks for the help!
Metadata
Metadata
Assignees
Labels
No labels