@mdfriday/foundry
Version:
The core engine of MDFriday. Convert Markdown and shortcodes into fully themed static sites – Hugo-style, powered by TypeScript.
40 lines • 992 B
TypeScript
import { FileMetaInfo } from '../../fs/type';
import { FileInfo } from './fileinfo';
export declare class Classifier {
private files;
constructor(files: FileInfo[]);
static newClassifier(fis: FileMetaInfo[]): Promise<Classifier>;
/**
* Sort files using the same logic as Go version
*/
private sort;
/**
* GetLeaf - returns the first leaf bundle file
*/
getLeaf(): FileInfo | null;
/**
* Get all files
*/
getFiles(): FileInfo[];
/**
* Get number of files
*/
length(): number;
/**
* Get file at index
*/
at(index: number): FileInfo | undefined;
/**
* Filter files by predicate
*/
filter(predicate: (file: FileInfo) => boolean): FileInfo[];
/**
* Find first file matching predicate
*/
find(predicate: (file: FileInfo) => boolean): FileInfo | undefined;
/**
* Check if empty
*/
isEmpty(): boolean;
}
//# sourceMappingURL=classifier.d.ts.map