diff --git a/.config/nvim/ftplugin/haskell.lua b/.config/nvim/ftplugin/haskell.lua index 29240dcf..744ccd73 100644 --- a/.config/nvim/ftplugin/haskell.lua +++ b/.config/nvim/ftplugin/haskell.lua @@ -4,6 +4,9 @@ opts.matchit_let_in() vim.bo.shiftwidth = 2 vim.bo.expandtab = true -local luasnip = require("luasnip") -local haskell_snippets = require("haskell-snippets").all -luasnip.add_snippets("haskell", haskell_snippets, { key = "haskell" }) +local once = require("once") +once.test_and_load("ft_haskell", function() + local luasnip = require("luasnip") + local haskell_snippets = require("haskell-snippets").all + luasnip.add_snippets("haskell", haskell_snippets, { key = "haskell" }) +end)