我正在关注https://docs.slatejs.org/walkthroughs/04-applying-custom-formatting上的石板教程
有一个函数调用 Text.isText(n),我不断收到 Type:Error Text.isText is not a function
toggleBoldMark(editor) {
const isActive = CustomEditor.isBoldMarkActive(editor)
Transforms.setNodes(
editor,
{ bold: isActive ? null : true },
{ match: n => Text.isText(n), split: true }
)
},