-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtypes.d.ts
62 lines (51 loc) · 1.09 KB
/
types.d.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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
export interface FunctionValue {
name: string;
type: string;
description: string;
}
export interface Field {
name: string;
description: string;
// Bruh.. no typing??
}
export interface TableValue {
realm: string;
name: string;
description: string;
fields: Field[] | undefined;
}
export interface Func {
path: string;
returns: FunctionValue[] | undefined;
params: FunctionValue[] | undefined;
realm: string;
name: string;
}
export interface Library {
methods: Func[];
tables: TableValue[];
fields: Field[] | undefined;
realm: string;
path: string;
name: string;
description: string;
}
export interface SFObject {
path: string;
name: string;
description: string;
methods: Func[];
}
export interface Hook {
name: string;
description: string;
}
export interface Docs {
Libraries: Record<string, Library>;
Types: Record<string, SFObject>;
Hooks: Record<string, Hook>;
Version: string;
}
// This is for supporting JSON overrides, currently you can only
// override the type of a generated function.
export type Overrides = Record<string, Record<string, Record<string, string>>>;