})
},
}])
+<
+ And this example will prefix the diagnostic message with
+ the string "TypeScript: ": >
+
+ vim9script
+ g:LspAddServer([{
+ filetype: ['javascript', 'typescript'],
+ path: '/usr/local/bin/typescript-language-server',
+ args: ['--stdio'],
+ processDiagHandler: (diags: list<dict<any>>) => {
+ return diags->map((diag, ix) => {
+ diag.message = $'TypeScript: {diag.message}'
+ return diag
+ })
+ },
+ }])
<
*lsp-cfg-syncInit*
syncInit (Optional) for language servers (e.g. rust analyzer,