After the upgrade I see TS error in my gql files where gql function from overmind-graphql is used:
Argument of type 'TemplateStringsArray' is not assignable to parameter of type 'Literals'.
Type 'TemplateStringsArray' is missing the following properties from type 'string[]': pop, push, reverse, shift, and 6 more.ts(2345)
@christianalfoni Hello!
I discovered a bug in
overmind-graphql
package. I upgraded all packages to the latest versions:After the upgrade I see TS error in my gql files where
gql
function fromovermind-graphql
is used:I took a look at the commits were made in
overmind-graphql
and I see the following change: https://github.com/cerebral/overmind/commit/576c7de4ded8916d86447938096e95a8aef3754b#diff-b00535046c2f50ff11c353cc982bfda7a948198ee6e371dfa81a951ead3876ebL127You extracted the type
from the function
But you removed
readonly
keyword (probably because an old version of prettier complains) and it causes the error.The fix would be to make the type be:
Then it corresponds to the type from gqlTag, fixes TS error and satisfies eslint/prettier.
Would you mind merging the PR that fixes the issue https://github.com/cerebral/overmind/pull/527?