UNPKG

1.19 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 type { Compilation } from 'webpack';
9export declare class WebpackResourceLoader {
10 private _parentCompilation?;
11 private _fileDependencies;
12 private _reverseDependencies;
13 private fileCache?;
14 private assetCache?;
15 private modifiedResources;
16 private outputPathCounter;
17 private readonly inlineDataLoaderPath;
18 constructor(shouldCache: boolean);
19 update(parentCompilation: Compilation, changedFiles?: Iterable<string>): void;
20 clearParentCompilation(): void;
21 getModifiedResourceFiles(): Set<string>;
22 getResourceDependencies(filePath: string): never[] | Set<string>;
23 getAffectedResources(file: string): never[] | Set<string>;
24 setAffectedResources(file: string, resources: Iterable<string>): void;
25 private _compile;
26 private _evaluate;
27 get(filePath: string): Promise<string>;
28 process(data: string, fileExtension: string | undefined, resourceType: 'template' | 'style', containingFile?: string): Promise<string>;
29}