Hi, I want to create a text node with some marks like emphasize.
I want do so via
const tr = view.state.tr.replaceRangeWith( range.from, range.to, view.state.schema.text(“test”, [view.state.schema.marks.em]) ) view.dispatch(tr)
This does not work - I get an error message “Uncaught TypeError: Cannot read property ‘excludes’ of undefined”.
It works, however, if I am removing the field for marks?
Do you know how to make this work?