UNPKG

1.21 kBTypeScriptView Raw
1import type { BiblioEntry } from './Biblio';
2import Spec from './Spec';
3import { CancellationToken } from 'prex';
4export type { Spec, BiblioEntry };
5export declare class Boilerplate {
6 address?: string;
7 copyright?: string;
8 license?: string;
9}
10export declare type EcmarkupError = {
11 ruleId: string;
12 message: string;
13 file?: string;
14 source?: string;
15 line?: number;
16 column?: number;
17 nodeType?: string;
18};
19export interface Options {
20 status?: 'proposal' | 'draft' | 'standard';
21 version?: string;
22 title?: string;
23 shortname?: string;
24 stage?: string | null;
25 copyright?: boolean;
26 date?: Date;
27 location?: string;
28 multipage?: boolean;
29 contributors?: string;
30 toc?: boolean;
31 oldToc?: boolean;
32 lintSpec?: boolean;
33 cssOut?: string;
34 jsOut?: string;
35 assets?: 'none' | 'inline' | 'external';
36 outfile?: string;
37 boilerplate?: Boilerplate;
38 ecma262Biblio?: boolean;
39 log?: (msg: string) => void;
40 warn?: (err: EcmarkupError) => void;
41}
42export declare function build(path: string, fetch: (path: string, token: CancellationToken) => PromiseLike<string>, opts?: Options, token?: CancellationToken): Promise<Spec>;