Building a realtime chat app with GraphQL Subscriptions
In this tutorial, learn how to build a real-time group chat application using Hasura GraphQL Engine without writing any backend code. The focus is on data models stored in Postgres rather than full chat functionality. Key points include creating a user signup mutation, updating the last_seen value of users every two seconds, subscribing to new message events and only fetching new messages, sending messages by inserting rows into the messages table, and managing UI typing indicators and an online users list through subscriptions. A live demo is available at https://realtime-chat.demo.hasura.io/.
Company
Hasura
Date published
Feb. 3, 2022
Author(s)
Rishichandra Wawhal
Word count
895
Hacker News points
None found.
Language
English