MCPcopy Create free account
hub / github.com/formatjs/formatjs / walkFragment

Function walkFragment

packages/cli-lib/svelte_extractor.ts:22–33  ·  view source on GitHub ↗
(
  fragment: SvelteNode | null | undefined,
  source: string,
  parseScriptFn: ScriptParseFn
)

Source from the content-addressed store, hash-verified

20}
21
22function walkFragment(
23 fragment: SvelteNode | null | undefined,
24 source: string,
25 parseScriptFn: ScriptParseFn
26): void {
27 if (!fragment || !fragment.nodes) {
28 return
29 }
30 for (const node of fragment.nodes) {
31 walkNode(node, source, parseScriptFn)
32 }
33}
34
35function extractExpression(
36 expression: SvelteNode | null | undefined,

Callers 2

walkNodeFunction · 0.85
parseFileFunction · 0.85

Calls 1

walkNodeFunction · 0.85

Tested by

no test coverage detected