/
types.ts
38 lines (31 loc) · 946 Bytes
/
types.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
export interface ILinkdashRow {
id?: string;
title: string;
href: string;
group: string;
keywords?: string;
count?: number;
isBookmarked?: boolean;
}
export interface IBaseLinkdashConfig {
enableAutoMenu?: boolean;
host?: string;
title?: string;
urls?: ILinkdashRow[];
}
// Options passed through a config file
export interface ILinkdashFileConfig extends IBaseLinkdashConfig {
htmlHead?: string;
output?: string | "text";
disableOpen?: boolean;
}
export type ILinkdashFileConfigFn = () => ILinkdashFileConfig;
export type ILinkdashCliMergedOptions = ILinkdashFileConfig & {
config?: string;
help?: string;
init?: boolean;
};
// Options passed through the cli
export type ILinkdashCliArgs = Omit<ILinkdashCliMergedOptions, "urls" | "htmlHead">;
export type IBuildTemplateOptions = Omit<ILinkdashFileConfig, "output" | "disableOpen">;
export type ILinkdashHostConfig = Omit<ILinkdashFileConfig, "output">;