Intro
- In this tutorial we're going to build a chat overlay for your Twitch streams. When you're done you'll have a chat overlay to use in your streams
- If you are a beginner at web dev, this is for you. In order to complete this tutorial, you'll need to know some HTML, CSS, JS. We'll need ComfyJS to complete the project
- You'll be able to use the skills and lessons in this tutorial in the real world when you want to build more complex and interactive overlays
Body
-
Brainstorm examples:
- A single big chatbox
- An animated chat
- A responsive chat
The example I'm going with is an animated chat because it's simple to achieve with clear instructions, doable within an hour, easy to modify to one's own tastes and at the end, you have a pretty impressive looking chat.
-
Steps involved
- Setup the HTML file
- Setup ComfyJS
- Test your connection with your account's Stream Manager
- Add the messages to the DOM
- Using
blockquote
to separate the sender and the message - Styling
- Fixed width on the body
- Adding style to the message
- Use
flex-direction:row-reverse
to make messages appear at the bottom of the container - Remove scrollbars
- Adding additional styles to make it look cute
- Adding the animation
- Adding keyframe animation to the
li:last-of-child
- Make the older messages transparent
- Adding keyframe animation to the
Add gif of chat here
The reader can test at each step of the tutorial by sending chat messages in their Twitch Stream Manager
Conclusion
- I'll challenge my readers to modify messages sent by their subscribers and mods
- Resources: ComfyCorner, AlexTrost, whitep4nth3r for inspiration for overlays
Top comments (0)