UNPKG

698 BTypeScriptView Raw
1import NodePatcher from './NodePatcher';
2import { PatcherContext } from './types';
3export default class ProgramPatcher extends NodePatcher {
4 body: NodePatcher | null;
5 helpers: Map<string, string>;
6 _indentString: string | null;
7 constructor(patcherContext: PatcherContext, body: NodePatcher | null);
8 shouldTrimContentRange(): boolean;
9 /**
10 * Register a helper to be reused in several places.
11 *
12 * FIXME: Pick a different name than what is in scope.
13 */
14 registerHelper(name: string, code: string): string;
15 patchHelpers(): void;
16 /**
17 * Gets the indent string used for each indent in this program.
18 */
19 getProgramIndentString(): string;
20}