/** * @license * Copyright 2021 Google LLC * SPDX-License-Identifier: BSD-3-Clause */ import ts from 'typescript'; /** * State scoped to one module that contains Lit code. */ export declare class LitFileContext { /** * Maps from a Lit module ImportSpecifier to the canonical name within the Lit * packages for that export. */ readonly litImports: Map; /** * Nodes that are to be replaced with another node (or removed when undefined) * when they are encountered in subsequent traversal. */ readonly nodeReplacements: Map; private readonly _program; constructor(program: ts.Program); clear(): void; /** * If the given node refers to a symbol imported from a Lit package, return * Lit's canonical name for that symbol. */ getCanonicalName(node: ts.Node): string | undefined; /** * Replace one AST node with another, copying over all associated comments. */ replaceAndMoveComments(oldNode: ts.Node, newNode: ts.Node): void; }