Skip to content

Is mixin two more object types into another object type supported? #532

Closed
@sjmittal

Description

@sjmittal

Example
I have two object types:

@ObjectType()
class A { .. }
@ObjectType()
class B { .. }

I want to create a new class C composed of fields from A and B.
Now typescript supports this and also there is a mixin example in type-graphql.
However the example is to mix only one class in some other class.

When I try to compose a new class the way typescript supports, it does not copy the decorators to the new class and the schema generated from that new class does not has the compose fields.

Any other way if this is possible?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Question ❔Not future request, proposal or bug issueWontfix ❌This will not be worked on

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions