Properly support prettier plugins
This commit is contained in:
parent
afee29ad3f
commit
8a807102a6
8 changed files with 100 additions and 33 deletions
|
@ -6,7 +6,7 @@ use futures::{
|
|||
FutureExt, StreamExt,
|
||||
};
|
||||
use gpui::AppContext;
|
||||
use language::{LanguageServerName, LspAdapter, LspAdapterDelegate};
|
||||
use language::{BundledFormatter, LanguageServerName, LspAdapter, LspAdapterDelegate};
|
||||
use lsp::LanguageServerBinary;
|
||||
use node_runtime::NodeRuntime;
|
||||
use serde_json::{json, Value};
|
||||
|
@ -127,6 +127,13 @@ impl LspAdapter for TailwindLspAdapter {
|
|||
.into_iter(),
|
||||
)
|
||||
}
|
||||
|
||||
fn enabled_formatters(&self) -> Vec<BundledFormatter> {
|
||||
vec![BundledFormatter::Prettier {
|
||||
parser_name: None,
|
||||
plugin_names: vec!["prettier-plugin-tailwindcss"],
|
||||
}]
|
||||
}
|
||||
}
|
||||
|
||||
async fn get_cached_server_binary(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue