From 3ad4afaf44f596e5a75a33b124c16d20f09311a6 Mon Sep 17 00:00:00 2001 From: David Barbet Date: Thu, 6 Jun 2024 13:13:03 -0700 Subject: [PATCH] Merge pull request #73852 from dibarbet/fix_tsx_lsp Add tsx/jsx as recognized extensions for TS --- .../LanguageServer/Protocol/LanguageInfoProvider.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/Features/LanguageServer/Protocol/LanguageInfoProvider.cs b/src/Features/LanguageServer/Protocol/LanguageInfoProvider.cs index ffa6c8563a4e2..6564c452ae721 100644 --- a/src/Features/LanguageServer/Protocol/LanguageInfoProvider.cs +++ b/src/Features/LanguageServer/Protocol/LanguageInfoProvider.cs @@ -30,7 +30,13 @@ internal class LanguageInfoProvider : ILanguageInfoProvider { ".razor", s_razorLanguageInformation }, { ".xaml", s_xamlLanguageInformation }, { ".ts", s_typeScriptLanguageInformation }, + { ".d.ts", s_typeScriptLanguageInformation }, + { ".tsx", s_typeScriptLanguageInformation }, { ".js", s_typeScriptLanguageInformation }, + { ".jsx", s_typeScriptLanguageInformation }, + { ".cjs", s_typeScriptLanguageInformation }, + { ".mjs", s_typeScriptLanguageInformation }, + { ".cts", s_typeScriptLanguageInformation }, }; public LanguageInformation GetLanguageInformation(string documentPath, string? lspLanguageId)