MCPcopy Create free account
hub / github.com/Noumena-Network/code / extractBalancedSegment

Function extractBalancedSegment

scripts/generate_slash_command_appendix.mjs:95–98  ·  view source on GitHub ↗
(source, startIndex, openChar, closeChar)

Source from the content-addressed store, hash-verified

93}
94
95function extractBalancedSegment(source, startIndex, openChar, closeChar) {
96 const endIndex = findMatchingDelimiter(source, startIndex, openChar, closeChar)
97 return source.slice(startIndex, endIndex + 1)
98}
99
100function extractArrayBodyFromAnchor(source, anchor) {
101 const anchorIndex = source.indexOf(anchor)

Callers 5

findCallObjectSourceFunction · 0.85
findIfBlocksFunction · 0.85

Calls 1

findMatchingDelimiterFunction · 0.85

Tested by

no test coverage detected