Skip to content

Commit 2657f81

Browse files
jadestrongzhangyuqiang
andauthored
feat(lsp-javascript): add support tsserver options (#3922)
Co-authored-by: zhangyuqiang <zhangyuqiang@bytedance.com>
1 parent d894e68 commit 2657f81

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

clients/lsp-javascript.el

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,12 @@ See https://github.com/typescript-language-server/typescript-language-server#ini
148148
:group 'lsp-typescript
149149
:type 'plist)
150150

151+
(defcustom lsp-clients-typescript-tsserver nil
152+
"Options related to the tsserver process. See below for more info.
153+
See https://github.com/typescript-language-server/typescript-language-server#initializationoptions for the list of tsserver available in the latest version of TypeScript."
154+
:group 'lsp-typescript
155+
:type 'plist)
156+
151157
(defcustom lsp-typescript-tsdk nil
152158
"Specifies the folder path containing tsserver and lib*.d.ts files to use."
153159
:type '(repeat string)
@@ -926,7 +932,9 @@ name (e.g. `data' variable passed as `data' parameter)."
926932
(when lsp-clients-typescript-plugins
927933
(list :plugins lsp-clients-typescript-plugins))
928934
(when lsp-clients-typescript-preferences
929-
(list :preferences lsp-clients-typescript-preferences))))
935+
(list :preferences lsp-clients-typescript-preferences))
936+
(when lsp-clients-typescript-tsserver
937+
(list :tsserver lsp-clients-typescript-tsserver))))
930938
:initialized-fn (lambda (workspace)
931939
(with-lsp-workspace workspace
932940
(lsp--set-configuration

0 commit comments

Comments
 (0)