Hi everyone,
I’m currently working on a Frappe-based SPA and trying to implement real-time updates on the frontend (Vue 3 app using the REST API). I’ve explored the built-in frappe.realtime.publish_realtime
and frappe.realtime.on
, but it appears these only work within the standard Frappe backend or server-rendered pages—not in a separate SPA served independently (e.g., via Vite).
To work around this, I created a custom WebSocket server (using socket.io
) on ports like 5200
, 6787
, etc., and everything works fine locally. However, when I try to deploy this on Frappe Cloud, it seems I can’t run anything on additional ports, which breaks the real-time connection.
I’d love to keep my frontend synced with backend changes without requiring a page refresh or manual polling. Has anyone found a clean and reliable solution for real-time frontend updates in a Frappe SPA on Frappe Cloud?
Any help, ideas, or even hacks would be greatly appreciated.
Thanks in advance!