UNPKG

509 BTypeScriptView Raw
1interface SourceLoc {
2 line: number;
3 col: number;
4}
5interface SourceBlock {
6 startBody: SourceLoc;
7 endBody: SourceLoc;
8 startLoc: SourceLoc;
9 endLoc: SourceLoc;
10}
11interface LocationsMap {
12 [key: string]: SourceBlock;
13}
14
15/** Given a location, extract the text from the full source */
16declare function extractSource(location: SourceBlock, lines: string[]): string | null;
17
18declare const _default: any;
19
20export { LocationsMap, SourceBlock, SourceLoc, _default as default, extractSource };