-
-
Notifications
You must be signed in to change notification settings - Fork 173
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Polka with Sapper and Apollo-server-express #64
Comments
I don't use GQL but it's probably expecting const server = polka();
graphQLServer.applyMiddleware({
app: server.handler,
path: '/graphql'
}); |
Apollo-server-express with Poka is working fine with the above code but If used with Sapper, we get 404 page. If we even define a simple route before Sapper middleware, we still get 404 page
|
Please post bare minimum reproduction or a larger snippet. I need more contacts to see what's going on. Thanks! |
Here is the complete code of app/server.js from Sapper template. Both routes (/hello, /graphql) showing 404 page and If I remove sapper middleware then both routes work fine. Same template code (Both routes with sapper middleware) is working fine with Expressjs. It seems its Polka specific issue.
|
Thanks! That helps Looks like you can add this in: sapper({ ignore: '/graphql', manifest }) You can see this PR for more info :: sveltejs/sapper#326 |
Its working now with ignore option. Thanks for the help. |
Awesome! 🙌 |
I am trying to use graphql apollo-server-express with Sapper-template but I am getting 404 page it seems sapper is not allowing to add a route. Here is my code.
Rich said on disord that it could be related to the way Polka runs middleware in a different order. Try using Express
@lukeed do you have any idea how to solve this issue.
The text was updated successfully, but these errors were encountered: