I implemented gifcast, a web page for converting asciinema casts to animated GIFs. Here’s the link:
https://dstein64.github.io/gifcast/
The JavaScript source code is available on GitHub:
https://github.com/dstein64/gifcast
The example below was generated with gifcast.

Here is the asciinema cast file used to generate the animated GIF: gifcast.cast