Custom props not mergin properly #1868
-
I started using blink cmp and I added a custom props (spec?) return {
{
"saghen/blink.cmp",
opts_extend = { "disable_ft" },
opts = {
-- custom props to disable blink in certain filetypes
disable_ft = { "prompt" },
-- my other config here
},
config = function(_, opts)
local disabled_filetypes = opts.disable_ft or {}
opts.enabled = function()
-- will use to disable completions on certain filetypes
return not vim.tbl_contains(disabled_filetypes, vim.bo.filetype) and vim.b.completion ~= false
end
opts.disable_ft = nil
-- this was added for debugging purposes
Utils.notify.info(vim.inspect(disabled_filetypes))
require("blink.cmp").setup(opts)
end,
},
} Now in other files, I just do things like return {
{
-- the plugin config here
},
{
"saghen/blink.cmp",
optional = true,
opts = {
disable_ft = { "oil" },
},
},
} I did this for oil, TelescopePrompt, neo-tree and prompt but it only merges the first two. The notifications shows just two. If I remove one, it shows two. I don't know what I am doing wrong, I can't find anything related in the docs. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I have been able to find out what's wrong, I was not loading blink before those custom config but I didn't think that would be a problem. |
Beta Was this translation helpful? Give feedback.
I have been able to find out what's wrong, I was not loading blink before those custom config but I didn't think that would be a problem.