typescript: Add support for VTSLS (#12606)
You can opt into using VTSLS instead of typescript-language-server by pasting the following snippet into your settings: ``` "languages": { "TSX": { "language_servers": [ "!typescript-language-server", "vtsls-language-server" ] } }, ``` Related to: #5166 Release Notes: - Added support for using [vtsls](https://github.com/yioneko/vtsls) language server for Typescript/Javascript.
This commit is contained in:
parent
2b21c89e3c
commit
b1efea1100
2 changed files with 254 additions and 12 deletions
|
@ -22,6 +22,7 @@ mod python;
|
|||
mod rust;
|
||||
mod tailwind;
|
||||
mod typescript;
|
||||
mod vtsls;
|
||||
mod yaml;
|
||||
|
||||
#[derive(RustEmbed)]
|
||||
|
@ -137,29 +138,33 @@ pub fn init(
|
|||
);
|
||||
language!(
|
||||
"tsx",
|
||||
vec![Arc::new(typescript::TypeScriptLspAdapter::new(
|
||||
node_runtime.clone()
|
||||
))]
|
||||
vec![
|
||||
Arc::new(typescript::TypeScriptLspAdapter::new(node_runtime.clone())),
|
||||
Arc::new(vtsls::VtslsLspAdapter::new(node_runtime.clone()))
|
||||
]
|
||||
);
|
||||
language!(
|
||||
"typescript",
|
||||
vec![Arc::new(typescript::TypeScriptLspAdapter::new(
|
||||
node_runtime.clone()
|
||||
))],
|
||||
vec![
|
||||
Arc::new(typescript::TypeScriptLspAdapter::new(node_runtime.clone())),
|
||||
Arc::new(vtsls::VtslsLspAdapter::new(node_runtime.clone()))
|
||||
],
|
||||
typescript_task_context()
|
||||
);
|
||||
language!(
|
||||
"javascript",
|
||||
vec![Arc::new(typescript::TypeScriptLspAdapter::new(
|
||||
node_runtime.clone()
|
||||
))],
|
||||
vec![
|
||||
Arc::new(typescript::TypeScriptLspAdapter::new(node_runtime.clone())),
|
||||
Arc::new(vtsls::VtslsLspAdapter::new(node_runtime.clone()))
|
||||
],
|
||||
typescript_task_context()
|
||||
);
|
||||
language!(
|
||||
"jsdoc",
|
||||
vec![Arc::new(typescript::TypeScriptLspAdapter::new(
|
||||
node_runtime.clone(),
|
||||
))]
|
||||
vec![
|
||||
Arc::new(typescript::TypeScriptLspAdapter::new(node_runtime.clone(),)),
|
||||
Arc::new(vtsls::VtslsLspAdapter::new(node_runtime.clone()))
|
||||
]
|
||||
);
|
||||
language!("regex");
|
||||
language!(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue