graphql / graphql/graphql.github.io

Schema Design: Use triple quotes for descriptions

Offen
#2,355 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
TypeScript
Sterne
889
Forks
1.5k
Ø Merge
4 T. 12 Std.
Gemergte PRs (30 T.)
21

Beschreibung

Use triple-quote syntax (`"""description"""`) for field and type documentation, not `#` symbols.

Rationale: Triple quotes are parsed as descriptions and appear in introspection and documentation tools. Hash comments are ignored by the parser and invisible to consumers.

**Example:**

Prefer:
```
"""
The business name
"""
name: String
```

Not:
```
# The business name
name: String
```

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.