Skip to content

Custom Directives #344

@t1

Description

@t1

I would like to be able to add Custom Directives to the generated schema. It would be convenient to add an @Directive annotation to my own annotation, i.e.:

@Directive(on = { FIELD, ARGUMENT })
public @interface Example {
    String value();
}

@Type
class SomeType {
    @Example("out")
    String field(@Example("in") int arg) { return null; }
}

...generates a schema:

type SomeType {
    field(arg: Int @example(value: "in")): String @example(value: "out")
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions