Interface: Formatter¶
Defined in: compiler/src/types.ts:48
Interface for formatters that convert AST to target format.
Properties¶
defaultConvention¶
readonlydefaultConvention:string
Defined in: compiler/src/types.ts:56
Default convention for this formatter
description¶
readonlydescription:string
Defined in: compiler/src/types.ts:54
Human-readable description
name¶
readonlyname:string
Defined in: compiler/src/types.ts:50
Formatter name (e.g., "github", "claude", "cursor")
outputPath¶
readonlyoutputPath:string
Defined in: compiler/src/types.ts:52
Output path pattern
Methods¶
format()¶
format(
ast,options?):FormatterOutput
Defined in: compiler/src/types.ts:58
Format the AST to target format
Parameters¶
ast¶
options?¶
Returns¶
getSkillBasePath()¶
getSkillBasePath():
string|null
Defined in: compiler/src/types.ts:60
Base path for skills (e.g., '.claude/skills'), or null if no skill support
Returns¶
string | null
getSkillFileName()¶
getSkillFileName():
string|null
Defined in: compiler/src/types.ts:62
Skill file name (e.g., 'SKILL.md' or 'skill.md'), or null if no skill support
Returns¶
string | null
referencesMode()¶
referencesMode():
"none"|"directory"|"inline"
Defined in: compiler/src/types.ts:64
How this formatter handles skill references: 'directory', 'inline', or 'none'
Returns¶
"none" | "directory" | "inline"
transformInjectedSkillContent()?¶
optionaltransformInjectedSkillContent(content):string
Defined in: compiler/src/types.ts:71
Optional hook to transform the raw content of a pass-through skill file (e.g. the bundled PromptScript SKILL.md) before it is written. Formatters whose target tools enforce frontmatter schemas can override this to strip unsupported fields.
Parameters¶
content¶
string
Returns¶
string