【发布时间】:2018-08-05 13:11:13
【问题描述】:
您好,我想在 graphql 中获取查询的类型名称。它不应该有标量和枚举类型。
schema {
query: Query
}
type LearningResource{
id: ID
name: String
type: String
children: [LearningResource]
}
type Query {
fetchLearningResource: LearningResource
}
当我运行fetchLearningResource 查询时,我想像这里LearningResource 一样获取它的类型。在 GraphQL 中有什么方法可以做到这一点?
【问题讨论】:
标签: javascript node.js graphql graphql-js