3 ms·
That is pretty neat. They use an invisible content editable field that moves to where the caret is placed. The content editable only contains the current word o
by madhato 9y ago
That is pretty neat. They use an invisible content editable field that moves to where the caret is placed. The content editable only contains the current word or selection.
Text typed into the content editable is rendered into SVG elements. Unfortunately that doesn't allow a browser's spellcheck to work so they had to implement their own.
iCloud Notes works in a similar way but it renders to canvas elements instead of SVG. Also doesn't provide spellcheck.