lazy load luasnip after cmp

This commit is contained in:
siduck76 2021-08-27 08:11:46 +05:30
parent 647c3730ae
commit c87482f107
2 changed files with 11 additions and 12 deletions

View file

@ -1,10 +1,9 @@
vim.opt.completeopt = "menuone,noselect"
local lspkind = require "plugins.configs.lspkind_icons"
local luasnip = require "luasnip"
local cmp = require "cmp"
-- nvim-cmp setup
local cmp = require "cmp"
cmp.setup {
snippet = {
expand = function(args)

View file

@ -176,25 +176,25 @@ return packer.startup(function()
-- load luasnips + cmp related in insert mode only
use {
"L3MON4D3/LuaSnip",
"hrsh7th/nvim-cmp",
event = "InsertEnter",
config = function()
require "plugins.configs.cmp"
end,
}
use {
"L3MON4D3/LuaSnip",
wants = "friendly-snippets",
after = "nvim-cmp",
config = function()
require "plugins.configs.luasnip"
end,
}
use {
"hrsh7th/nvim-cmp",
config = function()
require "plugins.configs.cmp"
end,
after = "LuaSnip",
}
use {
"saadparwaiz1/cmp_luasnip",
after = "nvim-cmp",
after = "LuaSnip",
}
use {