-
Notifications
You must be signed in to change notification settings - Fork 0
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
[component] Chat #32
Comments
@maticzav Right now, when a polling For example:
I'm thinking we will have to use some pagination, or something like that. Then our polling |
It seems that Struggling with the best approach for getting fresh messages in |
Yea, I see. Tricky question haha; I think we already have pagination set up for messages. Couldn't we do it in two ways? Fetch more one way and polls on the other side? |
I'm pretty sure the polling query overwrites the fetchMore, so that if we fetchMore and have 30 messages, the polling query will bring us back to 20. The polling doesn't append... I'm thinking we could use fetchMore with an interval. Basically hack together our own polling. There's probably a better way tho |
Are you sure about this? I would assume they must have addressed this somehow - this is such a regular use case! |
Basically, we have one query which has two parameters - |
@maticzav we may want to go for |
Have you found a way to solve this? |
@maticzav I have not... I can begin exploring |
I totally missed the last message! I think we should still try to get the functionality without subscriptions. Maybe we could push back subscriptions for a little while and finish everything else first. Tell me what you think! 🙂 |
Yeah I'm feeling this too. Chat will be something we iterate on a lot! |
Hey, I watched a Twitch stream last night and figured out we definitely need subscriptions. If we were to use polling instead, we could end up loading five messages at a time which is inferior user experience. Tell me about your experience with subscriptions so far. I believe there's a portion of documentation that I should want to read before we jump into implementing it. |
That's awesome to hear! I think it's important that we develop (and maintain) an understanding of other streaming products in the market, especially while streaming is relatively young. Subscriptions worked quite well for me until I began dealing with some Prisma errors. They directed me to use Once I was able to get the resolver/Prisma side working for subscriptions, it was pretty much a breeze. The interface with One thing I think we should look out for is configuring the |
Messages
Messages
(see https://github.com/homeroom-live/ui/blob/staging/src/components/Chat/ChatMessages.js)createMessage
Message
is fromteacher
The text was updated successfully, but these errors were encountered: