Introducing Rety: live coding, without the stress

I recently spoke at CSS Day in Amsterdam. It was only my second f2f talk after the pandemic. It went down really well, both in person, and recently that the video was released: Here is a sample of tweets about it that made me particularly warm and fuzzy inside: There’s a lot more where these […]


This content originally appeared on Lea Verou and was authored by Lea Verou

I recently spoke at CSS Day in Amsterdam. It was only my second f2f talk after the pandemic. It went down really well, both in person, and recently that the video was released:

Here is a sample of tweets about it that made me particularly warm and fuzzy inside:

There’s a lot more where these came from too.

This was not just my second post-pandemic talk, but my first talk using Rety, which is what this post is about.

As you may know, I love live coding as a teaching tool, and over the years it has become part of my trademark speaking style.

When combined with some kind of interactive preview, it allows the speaker to demonstrate not only the final state of a coding snippet, but also how you get there, and what the intermediate results are. Live coding is to programming what a blackboard is to math or physics.

But it does create a unique challenge: My live coded slides don’t make sense without me. This may be acceptable for a conference talk, which is usually recorded, but not in other contexts, such as teaching a university course, where all instructors need to be able to teach all lectures, and students need to be able to quickly refer to examples shown.

Back in the fall of 2021, when we were preparing for the second iteration of our course, Design for the Web: Languages and User Interfaces, this came up as a pressing issue. The current state of the course required me to be there to teach my lectures, and this may well be the last year I teach it, since I’m finishing up my PhD soon.

I didn’t want to completely remove live coding from my slides, as I truly believe it is the perfect implementation of the “show, don’t tell” teaching adage for certain things, so I thought instead: what if I could record my live coding, and make it replayable?

Doing so manually seemed like cruel and unusual punishment. And thus, Rety was born (pronounced like the “rety” in “retype”).

While originally the plan was for me to still live code, and have the Rety functionality there for students and future instructors, I ended up using it during my own lectures as well, as I concluded that a well crafted Rety script was strictly superior to me doing the live coding:

  • Same progressive development as a live demo
  • It still affords unplanned demonstrations (e.g. to answer a question), since Rety still works with the same editors, and I could always pause it and take over if needed.
  • I could record myself and edit the script to maximize education value and minimize typos, delays, fumbling etc.
  • People can consume typed text far faster than people can type text. This is why most video tutorials speed up the typing. With Rety, typing speed is adjustable, and doesn’t need to match mine.

After test driving it for our course the entire spring 2022 semester, it went through the ultimate test in June 2022: I used it for my CSSDay conference talk. You can watch the talk here (first live demo at 7:15).

Right now Rety is just a set of two classes: Recorder and Replayer, which are used entirely independently. The exact UI is left up to the Rety user. E.g. to use it in my slides, I integrated it with the Live Demo plugin of Inspire.js (it is automatically included if a <script class="demo-script" type="application/json"> is found in a live demo slide).

The library could use more docs and some tests and I have doubts about the API, but I figured I should release it it earlier rather than later (it’s already been sitting in a repo for 7 months). After all, what best time to release it than when the first Rety talk is still making the rounds?

My vision is to ultimately evolve and standardize the Rety script format, so that it can be used to describe a coding interaction across a variety of tools. There are so many possibilities!

  • Wouldn’t it be cool if CodePen and similar playgrounds supported embedding a Rety script into a pen?
  • What if you could store Rety scripts in a repo and editors like VS Code recognized them and let you replay them?

Enjoy: Rety


This content originally appeared on Lea Verou and was authored by Lea Verou


Print Share Comment Cite Upload Translate Updates
APA

Lea Verou | Sciencx (2022-07-13T16:50:09+00:00) Introducing Rety: live coding, without the stress. Retrieved from https://www.scien.cx/2022/07/13/introducing-rety-live-coding-without-the-stress/

MLA
" » Introducing Rety: live coding, without the stress." Lea Verou | Sciencx - Wednesday July 13, 2022, https://www.scien.cx/2022/07/13/introducing-rety-live-coding-without-the-stress/
HARVARD
Lea Verou | Sciencx Wednesday July 13, 2022 » Introducing Rety: live coding, without the stress., viewed ,<https://www.scien.cx/2022/07/13/introducing-rety-live-coding-without-the-stress/>
VANCOUVER
Lea Verou | Sciencx - » Introducing Rety: live coding, without the stress. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2022/07/13/introducing-rety-live-coding-without-the-stress/
CHICAGO
" » Introducing Rety: live coding, without the stress." Lea Verou | Sciencx - Accessed . https://www.scien.cx/2022/07/13/introducing-rety-live-coding-without-the-stress/
IEEE
" » Introducing Rety: live coding, without the stress." Lea Verou | Sciencx [Online]. Available: https://www.scien.cx/2022/07/13/introducing-rety-live-coding-without-the-stress/. [Accessed: ]
rf:citation
» Introducing Rety: live coding, without the stress | Lea Verou | Sciencx | https://www.scien.cx/2022/07/13/introducing-rety-live-coding-without-the-stress/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.