5 ms·
> TextKit2 is implemented to be used by UITextView This is the key insight that makes TextKit2 workable. I personally would not attempt to build an alternative
by arthurofbabylon 1y ago
> TextKit2 is implemented to be used by UITextView
This is the key insight that makes TextKit2 workable. I personally would not attempt to build an alternative to UITextView on TextKit (1 or 2). Instead, TextKit2 is all about very sensible intervention points for customizing UITextView (eg, Markdown-style parsing, typography, interactions, layout).
I recently rebuilt Minimal’s editor with TextKit2 (see minimal.app/#beta to experience it), and found Kryzanowskim’s deep dives very fruitful. He explores the edges of the API, so his writing helped me identify a nice bounds of safe-space to work in, and helped clarify what areas are too complex to safely build custom functionality within. (So thank you, author!)
I would not dismiss TextKit2; it is an incredible improvement over TextKit1. It remains a complicated and challenging field.
- lapcat 1y ago> I would not dismiss TextKit2; it is an incredible improvement over TextKit1. It's an absolute disaster on macOS. Even TextEdit app is now buggy as hell. It's incredible how Apple broke plain text display on the Mac, which was a solved problem since forever.
- krzyzanowskim 1y ago> I personally would not attempt to build an alternative to UITextView on TextKit (1 or 2) sure. If only UITextView/NSTextView did not have bugs impossible to workaround otherwise. TextKit 2 support in UITextView/NSTextView was really bad. improved over time. and still remain buggy. The UITextView focus limits the use of TextKit 2 architecture significantly.