MCPcopy Create free account
hub / github.com/bhsd-harry/wikiparser-node / text

Function text

util/string.ts:97–98  ·  view source on GitHub ↗
(childNodes: readonly (string | AstNodes)[], separator = '')

Source from the content-addressed store, hash-verified

95 * @param separator delimiter between nodes
96 */
97export const text = (childNodes: readonly (string | AstNodes)[], separator = ''): string =>
98 childNodes.map(child => typeof child === 'string' ? child : child.text()).join(separator);
99
100const names = {lt: '<', gt: '>', lbrack: '[', rbrack: ']', lbrace: '{', rbrace: '}', nbsp: ' ', amp: '&', quot: '"'};
101

Callers 11

textFunction · 0.90
innerTextFunction · 0.90
buildFromStrMethod · 0.90
sizeFunction · 0.90
getValueFunction · 0.90
textFunction · 0.90
textFunction · 0.90
textFunction · 0.90
textFunction · 0.90
syntaxListenerFunction · 0.90
safeReplaceChildrenFunction · 0.90

Calls 1

textMethod · 0.80

Tested by

no test coverage detected