docs: simplify cmp-emoji example

This commit is contained in:
Folke Lemaitre 2023-10-09 10:28:53 +02:00
parent a13d5c9076
commit 92b2689e6f
No known key found for this signature in database
GPG Key ID: 41F8B1FBACAE2040

View File

@ -44,8 +44,7 @@ return {
dependencies = { "hrsh7th/cmp-emoji" },
---@param opts cmp.ConfigSchema
opts = function(_, opts)
local cmp = require("cmp")
opts.sources = cmp.config.sources(vim.list_extend(opts.sources, { { name = "emoji" } }))
table.insert(opts.sources, { name = "emoji" })
end,
},