In the era of DOM documents (see notion, gitbook) I very often resort to attributed strings to do magic stuff with text parsing and manipulation. It’s such an elegant structure and I don’t understand why is so unknown.
Incredible article btw
Incredible article btw
With attributes strings it’s trivial, you just need to move attributes accordingly and to normalize stuff at the end.