refactor(lsp): pass module parameters to tsc requests (#29674)

This commit is contained in:
Nayeem Rahman 2025-06-10 02:31:14 +01:00 committed by GitHub
parent ccc30edcb5
commit cb9245c69a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 518 additions and 639 deletions

View file

@ -1090,13 +1090,7 @@ async fn generate_ts_diagnostics(
let mut enabled_modules_with_diagnostics = Vec::new();
for ((scope, notebook_uri), enabled_modules) in enabled_modules_by_scope {
let (diagnostics_list, ambient_modules) = ts_server
.get_diagnostics(
snapshot.clone(),
enabled_modules.iter().map(|m| m.specifier.as_ref()),
scope.as_ref(),
notebook_uri.as_ref(),
&token,
)
.get_diagnostics(snapshot.clone(), &enabled_modules, &token)
.await?;
enabled_modules_with_diagnostics
.extend(enabled_modules.into_iter().zip(diagnostics_list));