Browse Source

Autoformat on save

master
Taylor Bockman 1 year ago
parent
commit
b84694b5a1
  1. 7
      lua/conf/langs/general.lua

7
lua/conf/langs/general.lua

@ -23,6 +23,13 @@ require("mason").setup({
}) })
require("mason-lspconfig").setup() require("mason-lspconfig").setup()
-- Auto-format code on save
vim.api.nvim_create_autocmd({"BufWritePre"}, {
callback = function()
vim.lsp.buf.format()
end
})
-- Treesitter config. -- Treesitter config.
require'nvim-treesitter.configs'.setup { require'nvim-treesitter.configs'.setup {
ensure_installed = { ensure_installed = {

Loading…
Cancel
Save