In my HTML page, I have long text that has some auto-generated linebreaks at certain words (using line-break: normal), now a JavaScript library (vue-typer) types the same text but does line breaks at certain characters and doesn't support breaking the text at words.
So I wanted to fetch all linebreaks locations from the default HTML text and insert them into the vue-typer string so it will do line breaks at the same place.
So the question becomes: How to get the location of a linebreak from a DOM text?