add fn node.getIndex for alias node.index

This commit is contained in:
飞百 2020-05-11 22:44:32 +08:00
parent 38599fffa1
commit 83d6cd3b58

View File

@ -419,6 +419,13 @@ export class Node<Schema extends NodeSchema = NodeSchema> {
return this.parent.children.indexOf(this); return this.parent.children.indexOf(this);
} }
/**
* alias index
*/
getIndex = () => {
return this.index;
};
/** /**
* *
*/ */