I followed the Apollo Getting Started example in a Github Codespace.
Upon starting the server, I see the error:
{
"error": "Preflight response is not successful"
}
Sample repo to reproduce is here: https://github.com/anishkny/codespaces-test
I tried various options for cors
but it did not work:
...
new ApolloServer({ typeDefs, resolvers
cors: {
"origin": "*",
"methods": "GET,HEAD,PUT,PATCH,POST,DELETE",
"preflightContinue": false,
"optionsSuccessStatus": 204
}
});
...