Function: createSimpleMarkdownFormatter()¶
createSimpleMarkdownFormatter(
opts):SimpleFormatterResult
Defined in: formatters/src/create-simple-formatter.ts:106
Factory that creates a concrete MarkdownInstructionFormatter subclass and its companion VERSIONS constant from a small set of parameters.
Every formatter produced by this factory has identical runtime behaviour to the hand-written classes it replaces --- no method overrides, just different constructor config.
Parameters¶
opts¶
Returns¶
Example¶
export const { Formatter: WindsurfFormatter, VERSIONS: WINDSURF_VERSIONS } =
createSimpleMarkdownFormatter({
name: 'windsurf',
outputPath: '.windsurf/rules/project.md',
description: 'Windsurf rules (Markdown)',
mainFileHeader: '# Project Rules',
dotDir: '.windsurf',
});
export type WindsurfVersion = 'simple' | 'multifile' | 'full';