我在typedef文件中编写的描述性注释似乎未出现在Apollo Server 2.0 Playground UI中。这是屏幕截图
我正在使用gql
模块在NodeJS中创建typedef文件,如下所示:
const { gql } = require('apollo-server');
# Describes an album released by either a band or musician
type Album {
id: String
title: String
releaseDate: String
songs: [Song]
musician: Musician
band: Band
}
在此先感谢您的帮助!
答案 0 :(得分:0)
一位同事建议使用3个引号。它在def类型的开头起作用:
"""
musicians describes the composer(s) of the song
"""