MCPcopy
hub / github.com/continuedev/continue / parseBlock

Function parseBlock

packages/config-yaml/src/load/unroll.ts:73–81  ·  view source on GitHub ↗
(configYaml: string)

Source from the content-addressed store, hash-verified

71}
72
73export function parseBlock(configYaml: string): Block {
74 try {
75 const parsed = YAML.parse(configYaml);
76 const result = blockSchema.parse(parsed);
77 return result;
78 } catch (e: any) {
79 throw new Error(`Failed to parse block: ${formatZodError(e)}`);
80 }
81}
82
83export const TEMPLATE_VAR_REGEX = /\${{[\s]*([^}\s]+)[\s]*}}/g;
84

Callers

nothing calls this directly

Calls 1

formatZodErrorFunction · 0.85

Tested by

no test coverage detected