I’m pretty sure you can set alacritty and kitty to a ridiculously high number of scrollback lines, like at least several trillion. I think I just add 4 zeros on to the default and I’ve never had enough output for it to run out of scrollback. At some point you’re going to run out of ram or storage for storing scrollback so you can’t realistically have unlimited scrollback without doing something ridiculous.
https://www.gnu.org/software/tar/manual/html_section/Using-Multiple-Tapes.html
Might do kind of what you want.