relay-compiler-language-typescript
relay-compiler-language-typescript copied to clipboard
Fragment Typematching
I am sorry if this is not appropriate place to ask this question.
How do I get type when passing fragment, right now I have typecast them to any for typescript to stop complaining
Example
const CompanyHomePageQuery = graphql`
query CompanyHomeQuery {
viewer {
id
apps {
id
...AppHomeIcon_app
}
}
}
`
Now in my code fragment I have to do this
<AppHomeIcon
key={app.id}
app={app as any} // this is the problem I am trying to avoid
/>