At this moment, I create a MenuItem that produces a ul and a li as a child. See below:
run (state, dispatch) {
const li = schema.nodes.li.create()
const ul = schema.nodes.ul.create(null, li)
dispatch(state.tr.replaceSelectionWith(ul))
}
This code works great. But: how can I place the cursor directly after the child node (li)? After adding an ‘ul/li’ node, the cursor is placed after the ‘ul’… How can I fix this?