Skip to content
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

subscription confusion #437

Open
tzjoke opened this issue Dec 17, 2018 · 1 comment
Open

subscription confusion #437

tzjoke opened this issue Dec 17, 2018 · 1 comment

Comments

@tzjoke
Copy link

tzjoke commented Dec 17, 2018

Hi, I want to refactor my app with ts and i am quite confused with the subscription described in this example. I am used to using subscribe and resolve in subscription, like below:

const Subscription = {
    fooSub: {
        subscribe: 
        resolve:
    },
}

And in this example it is like

const Subscription: SubscriptionResolvers.Type<TypeMap> = {
    fooSub: parent => null
};

Can someone explain the flow here? Thanks in advance.

@Sampite
Copy link

Sampite commented Jul 23, 2019

Hey man, have you figured it out ? I'm refactoring my graphql server code to use typescript and I decided to use the same way as this app, but I can't get the subscriptions to work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants