Following this part of the documentation I was able to generate the corresponding types for my groq queries -> https://www.sanity.io/docs/sanity-typegen#c3ef15d8ad39
But I was wondering, let’s say I use this piece const *[_type == "author" && name == $name][0]{_type, name, description}
in many of my queries, is there a way to abstract that into the query while still having it detected by the typegen tool? I know that if I abstract that into a JS/TS variable it won’t be detected because it must be a string but maybe there is some other way I’m not aware of.
Thanks in advance.