disable formatter for php

This commit is contained in:
Alexander Navarro 2025-09-10 15:02:59 -03:00
parent 4458a8755e
commit dbde641e35

View file

@ -62,6 +62,14 @@ return {
config = function(_, opts) config = function(_, opts)
require("conform").setup(opts) require("conform").setup(opts)
vim.api.nvim_create_autocmd("FileType", {
pattern = { "php" },
callback = function(bufnr)
vim.b[bufnr].disable_autoformat
end,
})
end,
local function toggleAutoFormat() local function toggleAutoFormat()
-- to make this global, change b to g -- to make this global, change b to g
if vim.b.disable_autoformat == nil then if vim.b.disable_autoformat == nil then