diff --git a/lua/lazyvim/plugins/extras/lang/php.lua b/lua/lazyvim/plugins/extras/lang/php.lua index 334091bb..439e523d 100644 --- a/lua/lazyvim/plugins/extras/lang/php.lua +++ b/lua/lazyvim/plugins/extras/lang/php.lua @@ -35,4 +35,26 @@ return { } end, }, + { + "nvimtools/none-ls.nvim", + optional = true, + opts = function(_, opts) + local nls = require("null-ls") + opts.sources = opts.sources or {} + table.insert(opts.sources, nls.builtins.formatting.pretty_php) + end, + }, + { + "stevearc/conform.nvim", + optional = true, + dependencies = { + "williamboman/mason.nvim", + opts = { ensure_installed = { "pretty-php" } }, + }, + opts = { + formatters_by_ft = { + php = { "pretty-php" }, + }, + }, + }, }