1 | interface LineAndCharacter {
|
2 | line: number;
|
3 | character: number;
|
4 | }
|
5 | export interface DiagnosticMessage {
|
6 | messageText: string;
|
7 | category: DiagnosticCategory;
|
8 | }
|
9 | export interface Diagnostic {
|
10 | messageText: string | DiagnosticMessage[];
|
11 | category: DiagnosticCategory;
|
12 | target?: DiagnosticTarget;
|
13 | file?: {
|
14 | path: string;
|
15 | position?: {
|
16 | start: {
|
17 | line: number;
|
18 | };
|
19 | } | {
|
20 | start: LineAndCharacter;
|
21 | end?: LineAndCharacter;
|
22 | };
|
23 | };
|
24 | }
|
25 | export declare enum DiagnosticCategory {
|
26 | Warning = 0,
|
27 | Error = 1,
|
28 | Suggestion = 2,
|
29 | Message = 3
|
30 | }
|
31 | export declare enum DiagnosticTarget {
|
32 | App = "app",
|
33 | Companion = "companion",
|
34 | Settings = "settings"
|
35 | }
|
36 | export declare type DiagnosticHandler = (diagnostic: Diagnostic) => void;
|
37 | export declare const logDiagnosticToConsole: DiagnosticHandler;
|
38 | export {};
|