31 lines
No EOL
1,016 B
Text
31 lines
No EOL
1,016 B
Text
module namespace lint="lsp/lint";
|
||
(:
|
||
Describes a problem or hint for a piece of code.
|
||
|
||
from: number
|
||
|
||
The start position of the relevant text.
|
||
to: number
|
||
|
||
The end position. May be equal to from, though actually covering text is preferable.
|
||
severity: "error" | "hint" | "info" | "warning"
|
||
|
||
The severity of the problem. This will influence how it is displayed.
|
||
markClass?: string
|
||
|
||
When given, add an extra CSS class to parts of the code that this diagnostic applies to.
|
||
source?: string
|
||
|
||
An optional source string indicating where the diagnostic is coming from. You can put the name of your linter here, if applicable.
|
||
message: string
|
||
|
||
The message associated with this diagnostic.
|
||
renderMessage?: fn(view: EditorView) → Node
|
||
|
||
An optional custom rendering function that displays the message as a DOM node.
|
||
actions?: readonly Action[]
|
||
|
||
An optional array of actions that can be taken on this diagnostic.
|
||
|
||
|
||
:) |