Skip to content

Commit

Permalink
Add a completion for the off keyword
Browse files Browse the repository at this point in the history
Fixes #177
  • Loading branch information
razzeee committed Oct 19, 2019
1 parent c61d3bb commit 9cfbe85
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/providers/completionProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -436,6 +436,7 @@ export class CompletionProvider {
label: string,
snippetText: string | string[],
markdownDocumentation?: string,
kind?: CompletionItemKind,
): CompletionItem {
return {
documentation: {
Expand All @@ -446,7 +447,7 @@ export class CompletionProvider {
? snippetText.join("\n")
: snippetText,
insertTextFormat: InsertTextFormat.Snippet,
kind: CompletionItemKind.Snippet,
kind: kind || CompletionItemKind.Snippet,
label,
};
}
Expand All @@ -465,6 +466,12 @@ export class CompletionProvider {
"import ${1:Name} exposing (${2:..})",
"Unqualified import",
),
this.createSnippet(
"of",
["of", " $0"],
"The of keyword",
CompletionItemKind.Keyword,
),
this.createSnippet(
"case of",
[
Expand Down

0 comments on commit 9cfbe85

Please sign in to comment.