mirror of
https://github.com/LazyVim/LazyVim.git
synced 2025-06-21 08:35:53 +02:00
fix(haskell): Make Haskell-snippets lazy load for performance (#2676)
* fix(haskell): add filetype to haskell-snippets for lazy load * format haskell.lua --------- Co-authored-by: Uthman Mohamed <83053931+1239uth@users.noreply.github.com>
This commit is contained in:
parent
c0ad2209b6
commit
04bc5718a5
1 changed files with 14 additions and 13 deletions
|
@ -13,14 +13,14 @@ return {
|
|||
{
|
||||
"mrcjkb/haskell-tools.nvim",
|
||||
version = "^3",
|
||||
ft = { 'haskell', 'lhaskell', 'cabal', 'cabalproject' },
|
||||
ft = { "haskell", "lhaskell", "cabal", "cabalproject" },
|
||||
dependencies = {
|
||||
{ "nvim-telescope/telescope.nvim", optional = true },
|
||||
},
|
||||
config = function()
|
||||
local ok, telescope = pcall(require, 'telescope')
|
||||
local ok, telescope = pcall(require, "telescope")
|
||||
if ok then
|
||||
telescope.load_extension('ht')
|
||||
telescope.load_extension("ht")
|
||||
end
|
||||
end,
|
||||
},
|
||||
|
@ -33,8 +33,8 @@ return {
|
|||
end,
|
||||
},
|
||||
|
||||
{
|
||||
"mfussenegger/nvim-dap",
|
||||
{
|
||||
"mfussenegger/nvim-dap",
|
||||
optional = true,
|
||||
dependencies = {
|
||||
{
|
||||
|
@ -51,7 +51,7 @@ return {
|
|||
"nvim-neotest/neotest",
|
||||
optional = true,
|
||||
dependencies = {
|
||||
{ "mrcjkb/neotest-haskell", }
|
||||
{ "mrcjkb/neotest-haskell" },
|
||||
},
|
||||
opts = {
|
||||
adapters = {
|
||||
|
@ -62,23 +62,24 @@ return {
|
|||
|
||||
{
|
||||
"mrcjkb/haskell-snippets.nvim",
|
||||
dependencies = { "L3MON4D3/LuaSnip", },
|
||||
dependencies = { "L3MON4D3/LuaSnip" },
|
||||
ft = { "haskell", "lhaskell", "cabal", "cabalproject" },
|
||||
config = function()
|
||||
local haskell_snippets = require('haskell-snippets').all
|
||||
require('luasnip').add_snippets('haskell', haskell_snippets, { key = 'haskell' })
|
||||
local haskell_snippets = require("haskell-snippets").all
|
||||
require("luasnip").add_snippets("haskell", haskell_snippets, { key = "haskell" })
|
||||
end,
|
||||
},
|
||||
|
||||
{
|
||||
"luc-tielen/telescope_hoogle",
|
||||
ft = { 'haskell', 'lhaskell', 'cabal', 'cabalproject' },
|
||||
ft = { "haskell", "lhaskell", "cabal", "cabalproject" },
|
||||
dependencies = {
|
||||
{ "nvim-telescope/telescope.nvim" },
|
||||
},
|
||||
config = function()
|
||||
local ok, telescope = pcall(require, 'telescope')
|
||||
local ok, telescope = pcall(require, "telescope")
|
||||
if ok then
|
||||
telescope.load_extension('hoogle')
|
||||
telescope.load_extension("hoogle")
|
||||
end
|
||||
end,
|
||||
},
|
||||
|
@ -90,7 +91,7 @@ return {
|
|||
opts = {
|
||||
setup = {
|
||||
hls = function()
|
||||
return true
|
||||
return true
|
||||
end,
|
||||
},
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue