Get index of character after which variable 'word' must be broken given variable 'length' (accounts for wide characters). https://www.npmjs.com/package/breakword
CKEditor 5: wordbreak Plugin. Adds the <wbr> HTML element to CKEditor 5 in TYPO3. If set in a long word, the browser may break a line (without adding a hyphen character). Useful e.g. for long URLs and file paths.