Module: GraphQL::Schema::Printer::TypeKindPrinters::DescriptionPrinter
- Included in:
- ArgsPrinter, DirectivePrinter, EnumPrinter, FieldPrinter, InputObjectPrinter, InterfacePrinter, ObjectPrinter, ScalarPrinter, UnionPrinter
- Defined in:
- lib/graphql/schema/printer.rb
Instance Method Summary collapse
Instance Method Details
#print_description(definition, indentation = '', first_in_block = true) ⇒ Object
95 96 97 98 99 100 |
# File 'lib/graphql/schema/printer.rb', line 95 def print_description(definition, indentation='', first_in_block=true) return '' unless definition.description description = indentation != '' && !first_in_block ? "\n" : "" description << GraphQL::Language::Comments.commentize(definition.description, indent: indentation) end |