blob: 051cb208b8e5e488325967b36f8672a271854b68 (
plain)
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
|
" Author: Mohammed Chelouti - https://github.com/motato1
" Description: Deno lsp linter for TypeScript files.
call ale#linter#Define('typescript', {
\ 'name': 'deno',
\ 'lsp': 'stdio',
\ 'executable': function('ale#handlers#deno#GetExecutable'),
\ 'command': '%e lsp',
\ 'project_root': function('ale#handlers#deno#GetProjectRoot'),
\ 'initialization_options': function('ale_linters#typescript#deno#GetInitializationOptions'),
\})
function! ale_linters#typescript#deno#GetInitializationOptions(buffer) abort
let l:options = {
\ 'enable': v:true,
\ 'lint': v:true,
\ 'unstable': v:false,
\ }
if ale#Var(a:buffer, 'deno_unstable')
let l:options.unstable = v:true
endif
return l:options
endfunction
|