mirror of
https://github.com/chenasraf/vim-matchup.git
synced 2026-05-18 01:38:57 +00:00
22 lines
434 B
Lua
22 lines
434 B
Lua
if not pcall(require, 'nvim-treesitter') then
|
|
return {init = function() end}
|
|
end
|
|
|
|
local treesitter = require 'nvim-treesitter'
|
|
local queries = require 'nvim-treesitter.query'
|
|
|
|
local M = {}
|
|
|
|
function M.init()
|
|
treesitter.define_modules {
|
|
matchup = {
|
|
module_path = 'treesitter-matchup.internal',
|
|
is_supported = function(lang)
|
|
return queries.get_query(lang, 'matchup') ~= nil
|
|
end
|
|
}
|
|
}
|
|
end
|
|
|
|
return M
|