如何在Graphql.js中使用GraphQL的订阅 [英] How to use subscription of GraphQL in Graphql.js
问题描述
我正在使用继电器全栈.它正在使用GraphQL.js
.我想在GraphQL.js
中使用GraphQL的订阅.但是我在 GraphQL.js 中找不到有关GraphQL订阅的文档.
我可以在GraphQL.js
中使用GraphQL的订阅吗?
还是不支持?
I am using relay-fullstack. It's using GraphQL.js
. I want use subscription of GraphQL in GraphQL.js
. But I can't find documents about subscription of GraphQL in GraphQL.js.
Can I use subscription of GraphQL in GraphQL.js
?
Or does not it support that?
推荐答案
可以!我基于Facebook Relay-examples创建了一个简单的存储库,它具有订阅支持(服务器和客户端),可以进行现代更新,您可以查看一下,将来我也可能会对其进行改进: https://github.com/jeremy-colin/relay-examples-subscription
Yes you can! I created a simple repository based on Facebook relay-examples todo relay modern with subscriptions support (server and client), you can check it out, I might also improve it in the future: https://github.com/jeremy-colin/relay-examples-subscription
这篇关于如何在Graphql.js中使用GraphQL的订阅的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!