@felixgeelhaar/cclint
Version:
Catch CLAUDE.md drift before Claude misbehaves. Lints CLAUDE.md, skills, subagents, and hooks for Claude Code projects.
62 lines • 1.82 kB
TypeScript
import { Location } from './Location.js';
/**
* Represents a code block found within a CLAUDE.md file
*/
export declare class CodeBlock {
readonly language: string;
readonly content: string;
readonly location: Location;
readonly context: string;
readonly isComplete: boolean;
readonly hasImports: boolean;
readonly metadata: CodeBlockMetadata;
constructor(language: string, content: string, location: Location, context?: string, metadata?: Partial<CodeBlockMetadata>);
/**
* Get the lines of code as an array
*/
getLines(): string[];
/**
* Get the number of lines in the code block
*/
getLineCount(): number;
/**
* Check if this code block appears to be complete and runnable
*/
private checkCompleteness;
/**
* Check if the code block contains import statements
*/
private checkImports;
/**
* Normalize language identifiers to standard names
*/
private normalizeLanguage;
/**
* Get a display name for the language
*/
getLanguageDisplayName(): string;
/**
* Check if this is a supported programming language
*/
isSupportedLanguage(): boolean;
/**
* Get file extension for this language
*/
getFileExtension(): string;
}
/**
* Metadata about a code block
*/
export interface CodeBlockMetadata {
/** Indentation level in the markdown file */
indentLevel: number;
/** Whether this is intended as an example */
isExample: boolean;
/** Whether this demonstrates an anti-pattern */
isAntiPattern: boolean;
/** Description or title of the code block */
description: string;
/** Any additional attributes from the markdown */
attributes?: Record<string, unknown>;
}
//# sourceMappingURL=CodeBlock.d.ts.map