Skip to content

Commit

Permalink
feat(tsserver): set some tsserver formatting settings to their Neovim…
Browse files Browse the repository at this point in the history
… equivalents. Also used for organize imports
  • Loading branch information
folke committed Apr 21, 2023
1 parent 0328212 commit eb92903
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions lua/lazyvim/plugins/extras/lang/typescript.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,20 @@ return {
---@type lspconfig.options.tsserver
tsserver = {
settings = {
typescript = {
format = {
indentSize = vim.o.shiftwidth,
convertTabsToSpaces = vim.o.expandtab,
tabSize = vim.o.tabstop,
},
},
javascript = {
format = {
indentSize = vim.o.shiftwidth,
convertTabsToSpaces = vim.o.expandtab,
tabSize = vim.o.tabstop,
},
},
completions = {
completeFunctionCalls = true,
},
Expand Down

0 comments on commit eb92903

Please sign in to comment.