diff options
author | adamstuck <adam.moloney.stuck@gmail.com> | 2022-03-12 17:38:32 +0100 |
---|---|---|
committer | adamstuck <adam.moloney.stuck@gmail.com> | 2022-03-13 18:07:03 +0100 |
commit | 7b46477a3ddd6ce80736cc058d2f7f3b58fdb966 (patch) | |
tree | bd3ad020f28d368fcd268038e3a47ff695ebac51 /.config/nvim/lua/setup/nvim-cmp.lua | |
parent | 082c8cfa8fd385dff9b1662d0a58529ff89284b7 (diff) |
nvim: better lazy loading
Diffstat (limited to '.config/nvim/lua/setup/nvim-cmp.lua')
-rw-r--r-- | .config/nvim/lua/setup/nvim-cmp.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/.config/nvim/lua/setup/nvim-cmp.lua b/.config/nvim/lua/setup/nvim-cmp.lua index 42bf348..584da73 100644 --- a/.config/nvim/lua/setup/nvim-cmp.lua +++ b/.config/nvim/lua/setup/nvim-cmp.lua @@ -1,6 +1,6 @@ local has_words_before = function() - local line, col = unpack(vim.api.nvim_win_get_cursor(0)) - return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil + local line, col = unpack(vim.api.nvim_win_get_cursor(0)) + return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil end local luasnip = require("luasnip") |