CodeFTW/future-web

Configure CORS

Closed this issue · 3 comments

Configure CORS

@filipenevola Can you assign this issue to me?

Yep, this is easy

 import cors from "cors";

const schema = makeExecutableSchema({
  typeDefs,
  resolvers
});

createApolloServer(
  {
    schema
  },
  {
    configServer: graphQLServer => graphQLServer.use(cors())
  }
);

Yes, I know