mirumee/ariadne

Factor common schema directives logic used by make_executable_schema from SchemaDirectiveVisitor

rafalp opened this issue · 0 comments

Currently SchemaDirectiveVisitor does two things:

  • Its a base class for custom GraphQL directives.
  • Its a manager class for directives, with visit_schema_directives and get_declared_directives classmethods that make_executable_schema uses to apply directives to the schema

We should introduce new abstraction called SchemaDirective that extends SchemaVisitor, but only adds directive-specific logic, and move management/schema visiting logic to utility functions. SchemaDirectiveVisitor should then be deprecated.