diff --git a/lua/core/default_config.lua b/lua/core/default_config.lua index ba5fb91..98ecbb6 100644 --- a/lua/core/default_config.lua +++ b/lua/core/default_config.lua @@ -43,9 +43,6 @@ M.plugins = { lspconfig = { setup_lspconf = "", -- path of lspconfig file }, - luasnip = { - snippet_paths = {""}, -- list of custom snippet locations - }, }, } diff --git a/lua/plugins/configs/others.lua b/lua/plugins/configs/others.lua index b78bde5..a78c71e 100644 --- a/lua/plugins/configs/others.lua +++ b/lua/plugins/configs/others.lua @@ -1,7 +1,6 @@ local M = {} local load_override = require("core.utils").load_override -local load_config = require("core.utils").load_config M.autopairs = function() local present1, autopairs = pcall(require, "nvim-autopairs") @@ -113,9 +112,8 @@ M.luasnip = function() options = load_override(options, "L3MON4D3/LuaSnip") luasnip.config.set_config(options) - snippet_paths = load_config().plugins.options.luasnip.snippet_paths require("luasnip.loaders.from_vscode").lazy_load() - require("luasnip.loaders.from_vscode").lazy_load({ paths = snippet_paths }) + require("luasnip.loaders.from_vscode").lazy_load({ paths = vim.g.luasnippets_path or "" }) vim.api.nvim_create_autocmd("InsertLeave", { callback = function()