📜  basic express graphql - Javascript 代码示例

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

代码示例1
const express = require("express");
const expressGraphQL = require("express-graphql").graphqlHTTP;

const app = express();

app.use(
  "/graphql",
  expressGraphQL({
    graphiql: true,
  })
);

app.listen(5000, () => console.log("Server run on http://localhost:5000/"));