Looking to master AI text streaming with HTMX, (without writing a single line of JavaScript)?
In this video I break down how to set up a uni-directional SSE (Server Sent Events) endpoint and infuse HTML templates with reactivity using HTMX.
I will also share a workaround to prevent unwanted browser reconnection after the SSE connection ends.
This is the stack powering RustGPT, a ChatGPT clone I built with HTMX and Rust.
🧑🏽💻 The code is here: https://github.com/bitswired/rustgpt
🚀 Try RustGPT: https://rustgpt.bitswired.com/
Remember to subscribe to stay updated with more programming hacks, AI tips, and tricks.
🌐 Visit my blog at: https://www.bitswired.com
📩 Subscribe to the newsletter: https://newsletter.bitswired.com/
🔗 Socials:
LinkedIn: / jimi-vaubien
Twitter: / bitswired
Instagram: / bitswired
TikTok: / bitswired
00:00 Intro
00:32 HTMX and SSE
01:31 HTMX Streaming Implementation
03:18 Overcoming Browser Auto Reconnection
04:19 Going Further