-
-
Notifications
You must be signed in to change notification settings - Fork 367
/
config.ts
56 lines (54 loc) · 1.25 KB
/
config.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
import * as vscode from 'vscode';
const _config = () => vscode.workspace.getConfiguration('vue');
export const config = {
update: (section: string, value: any) => _config().update(section, value),
get splitEditors(): Readonly<{
icon: boolean;
layout: { left: string[], right: string[]; };
}> {
return _config().get('splitEditors')!;
},
get doctor(): Readonly<{
status: boolean;
}> {
return _config().get('doctor')!;
},
get server(): Readonly<{
hybridMode: boolean;
maxOldSpaceSize: number;
maxFileSize: number;
diagnosticModel: 'push' | 'pull';
additionalExtensions: string[];
vitePress: {
supportMdFile: boolean;
};
petiteVue: {
supportHtmlFile: boolean;
};
}> {
return _config().get('server')!;
},
get updateImportsOnFileMove(): Readonly<{
enabled: boolean;
}> {
return _config().get('updateImportsOnFileMove')!;
},
get codeActions(): Readonly<{
enabled: boolean;
}> {
return _config().get('codeActions')!;
},
get codeLens(): Readonly<{
enabled: boolean;
}> {
return _config().get('codeLens')!;
},
get complete(): Readonly<{
casing: {
props: 'autoKebab' | 'autoCamel' | 'kebab' | 'camel';
tags: 'autoKebab' | 'autoPascal' | 'kebab' | 'pascal';
};
}> {
return _config().get('complete')!;
},
};