add a has method to mirror for checking whether an id is in the map

This commit is contained in:
Yanzhen Yu
2018-10-31 12:06:32 +08:00
parent 7b9e57bd6c
commit 8acf670a99
2 changed files with 6 additions and 2 deletions

View File

@@ -209,8 +209,9 @@ export type inputCallback = (v: inputValue & { id: number }) => void;
export type Mirror = {
map: idNodeMap;
getId: (n: INode) => number;
getNode: (id: number) => INode;
getNode: (id: number) => INode | null;
removeNodeFromMap: (n: INode) => void;
has: (id: number) => boolean;
};
export type throttleOptions = {