Closed piotrski closed 11 months ago
Schema:
{ name: 'content', type: 'array', title: 'Content', of: [ { type: 'youtube', }, { name: 'productSection', type: 'productSection', title: 'Products', } ] }
Data:
content: [ { "_key": "9d0a582dd846" "_type": "youtube" "url": "..." }, { "_key": "c4c84d3114c9" "_type": "productSection" "products": [...] 1 item "title": "Prodct module" } ]
Type:
{ content: Ref_9GdYNyKK3JQZWeEb | Ref_rxXogl98csCHdj1D } type Ref_9GdYNyKK3JQZWeEb = { _key: string; // it's missing _type: "youtube"; // missing url?: string; videoLabel?: string; }; type Ref_rxXogl98csCHdj1D = | { _key: string; // it's missing _type: "productSection" // missing products?: Ref_xVWTU39k4Au07eM0[]; title?: string; }[] | null;
This might be related to https://github.com/ricokahler/sanity-codegen/issues/85 I'm using groq-codegen v1.0.0-alpha.25
I face up with the same issue with reference type missing _type and _key. Any walkaround?
I also need access to the _key property in my models.
_key
Schema:
Data:
Type:
This might be related to https://github.com/ricokahler/sanity-codegen/issues/85 I'm using groq-codegen v1.0.0-alpha.25