1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 | import { ResolvedUrl, UrlResolver } from 'polymer-analyzer';
|
15 | import { ProjectConfig } from 'polymer-project-config';
|
16 | import File = require('vinyl');
|
17 | import { AsyncTransformStream } from './streams';
|
18 |
|
19 |
|
20 |
|
21 |
|
22 | export declare class AddPrefetchLinks extends AsyncTransformStream<File, File> {
|
23 | files: Map<ResolvedUrl, File>;
|
24 | private _analyzer;
|
25 | private _config;
|
26 | constructor(config: ProjectConfig);
|
27 | protected _transformIter(files: AsyncIterable<File>): AsyncIterable<File>;
|
28 | }
|
29 | /**
|
30 | * Returns the given HTML updated with import or prefetch links for the given
|
31 | * dependencies. The given url and deps are expected to be project-relative
|
32 | * URLs (e.g. "index.html" or "src/view.html") unless absolute parameter is
|
33 | * `true` and there is no base tag in the document.
|
34 | */
|
35 | export declare function createLinks(urlResolver: UrlResolver, html: string, baseUrl: ResolvedUrl, deps: Set<ResolvedUrl>, absolute?: boolean): string;
|