📜  heroku 上的 graphql 游乐场错误请求 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:21.695000             🧑  作者: Mango

代码示例1
export const server = new ApolloServer({
  schema: applyMiddleware(makeExecutableSchema({ typeDefs, resolvers })),
  uploads: false,
  introspection: true,
  playground: true,
  formatError: ({ message, positions, originalError }) => ({ message, positions, originalError }),
  formatResponse: ({ data, errors, http }) => ({ data, errors, http })
})