I need to write a stylised font preview on the screen as a user types into a text box - like this (though I think this uses dated coding techniques): https://www.pet-tags.co.uk/engravingdetail?product=57&size=2
I can't find a specific example doing this - I found this question which is similar but doesn't write out the output to the screen: Best way to track onchange as-you-type in input type="text"?
I'd like to ensure this is done in a modern way with wide contemporary browser support (so excluding, say, IE8 is fine).
I can find no specific examples of this online.
Thanks.