MichalLytek / MichalLytek/type-graphql
A type does not implement an interface with a complex field
@MichalLytek is already working on this.
Since Jun 3, 2021.
- Dominant language
- TypeScript
- Stars
- 8.1k
- Forks
- 672
- PR merge metrics
- No merged PRs in 30d
Description
**Describe the Bug**
The generated schema does not properly handle the inheritance of interfaces having a non-scalar field. More concretely, an object type declared to implement an interface does not show up as an implementation in the schema.
**To Reproduce**
A repo with a reproducible example: https://github.com/dzhelezov/type-graphql-interface-example
Run with `yarn ts-node src/index.ts` and inspect `src/schema.gql`:
```gql
type EventImpl {
....
}
```
**Expected Behavior**
(Referring to the repo above): The generated schema includes `type EventImpl implements IEvent`
**Environment (please complete the following information):**
- OS: [MacOS]
- Node: v12.19.0
- Package version: 1.1.1
- TypeScript version: 3.9.9
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.