ProseMirror的schema可以定义node的content,比如让段落只允许inline元素,试了下还蛮好用的。
const schema = new Schema({
nodes: {
paragraph: {
content: "inline*",
},
},
});
登录/注册