@storybook/source-loader
Version:
21 lines (17 loc) • 509 B
TypeScript
interface SourceLoc {
line: number;
col: number;
}
interface SourceBlock {
startBody: SourceLoc;
endBody: SourceLoc;
startLoc: SourceLoc;
endLoc: SourceLoc;
}
interface LocationsMap {
[key: string]: SourceBlock;
}
/** Given a location, extract the text from the full source */
declare function extractSource(location: SourceBlock, lines: string[]): string | null;
declare const _default: any;
export { LocationsMap, SourceBlock, SourceLoc, _default as default, extractSource };