MCPcopy
hub / github.com/marktext/marktext / reduce

Method reduce

packages/muya/src/block/base/parent.ts:162–167  ·  view source on GitHub ↗
(
        callback: (memo: M, cur: TreeNode, i: number) => M,
        initialValue: M,
    )

Source from the content-addressed store, hash-verified

160 }
161
162 reduce<M>(
163 callback: (memo: M, cur: TreeNode, i: number) => M,
164 initialValue: M,
165 ): M {
166 return this.children.reduce<M>(callback, initialValue);
167 }
168
169 /**
170 * Use the `block` to replace the current block(this)

Callers 15

lengthMethod · 0.95
wordCountFunction · 0.45
namespaceFunction · 0.45
_emitStateChangeMethod · 0.45
rules.tsFile · 0.45
htmlTagFunction · 0.45
outputMethod · 0.45
delEmStrongFacFunction · 0.45
referenceLinkFunction · 0.45
linkFunction · 0.45
config.tsFile · 0.45
getLabelFromEventFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected