UNPKG

1.17 kBTypeScriptView Raw
1/**
2 * @license
3 * Copyright Google LLC All Rights Reserved.
4 *
5 * Use of this source code is governed by an MIT-style license that can be
6 * found in the LICENSE file at https://angular.io/license
7 */
8import { workspaces } from '@angular-devkit/core';
9import { Tree } from '@angular-devkit/schematics/src/tree/interface';
10import * as ts from 'typescript';
11export declare function getProject(host: Tree, projectName: string): Promise<workspaces.ProjectDefinition>;
12export declare function stripTsExtension(file: string): string;
13export declare function getOutputPath(host: Tree, projectName: string, target: 'server' | 'build'): Promise<string>;
14export declare function findImport(sourceFile: ts.SourceFile, moduleName: string, symbolName: string): ts.NamedImports | null;
15export type Import = {
16 name: string;
17 importModule: string;
18 node: ts.ImportDeclaration;
19};
20/** Gets import information about the specified identifier by using the Type checker. */
21export declare function getImportOfIdentifier(typeChecker: ts.TypeChecker, node: ts.Identifier): Import | null;
22export declare function addInitialNavigation(node: ts.CallExpression): ts.CallExpression;