From c5ca61177ae145f8758dd3c799513a9ec16d2744 Mon Sep 17 00:00:00 2001 From: Alex Date: Sun, 19 Nov 2023 16:07:14 +0100 Subject: [PATCH 1/2] use neovim core treesitter API instead of nvim-treesitter plugin --- lua/outline/utils/jsx.lua | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/lua/outline/utils/jsx.lua b/lua/outline/utils/jsx.lua index 376c198..3fb80cd 100644 --- a/lua/outline/utils/jsx.lua +++ b/lua/outline/utils/jsx.lua @@ -96,16 +96,13 @@ function M.parse_ts(root, children, bufnr) end function M.get_symbols(bufnr) - local status, parsers = pcall(require, 'nvim-treesitter.parsers') + bufnr = bufnr or 0 + local status, parser = pcall(vim.treesitter.get_parser, bufnr) if not status then return {} end - bufnr = bufnr or 0 - - local parser = parsers.get_parser(bufnr) - if parser == nil then return {} end From 44f2a4160ce77e181d5de4d125f63a270ff6d4cd Mon Sep 17 00:00:00 2001 From: hedyhli Date: Tue, 21 Nov 2023 00:43:07 +0000 Subject: [PATCH 2/2] Auto generate vim docs --- doc/outline.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/outline.txt b/doc/outline.txt index f4d2ef0..7040bdb 100644 --- a/doc/outline.txt +++ b/doc/outline.txt @@ -19,7 +19,7 @@ Table of Contents *outline-table-of-contents* PREREQUISITES *outline-prerequisites* - Neovim 0.7+ -- Properly configured Neovim LSP client +- Properly configured Neovim LSP client (otherwise only markdown is supported) INSTALLATION *outline-installation*