How to prevent splitting a block?


i have a schema with a “block_list” containing “block_item+”. All is well… except that when i select a block_item and type some characters, it splits the block_list in two, and it doesn’t make sense in that situation. I’m seeking an advice on the best approach to implement this (confusingly feeling that setting up a keydown event handler is not the right thing).

What is the behavior you want to happen when something is typed at that point? And are these block items textblock-type nodes, or something else?

The behavior i want to enforce is that typed text goes before or after the block_list when a block_item is selected - or best, is just ignored.

The block_items are nodeViews with a dom and no contentDOM.

This sounds like something you’d have to write a custom handleTextInput prop for

Worked perfectly as needed. Thank you for the tip.

Idea: some nodes are really not meant to be split, or should split in a custom way defined by node type. It would be nice to be able to customize that independently of what’s causing the split.