sdy

add passport into server

......@@ -3,6 +3,8 @@ dotenv.config();
import { GraphQLServer } from "graphql-yoga";
import morgan from "morgan";
import schema from "./schema";
import "./passport";
import { authenticateJWT } from "./passport";
const PORT = process.env.PORT;
......@@ -12,5 +14,6 @@ const server = new GraphQLServer({
});
server.express.use(morgan("dev"));
server.express.use(authenticateJWT);
server.start(() => console.log(`server is running : http://localhost:${PORT}`));
......