emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/treesit-fold e334470a17 203/417: update


From: ELPA Syncer
Subject: [nongnu] elpa/treesit-fold e334470a17 203/417: update
Date: Mon, 1 Jul 2024 10:02:26 -0400 (EDT)

branch: elpa/treesit-fold
commit e334470a17d1d0c71e32d6f397d50e46d4a36564
Author: Jen-Chieh <jcs090218@gmail.com>
Commit: Jen-Chieh <jcs090218@gmail.com>

    update
---
 README.md | 13 ++++++++++++-
 1 file changed, 12 insertions(+), 1 deletion(-)

diff --git a/README.md b/README.md
index a3dab4c831..763e6c44f6 100644
--- a/README.md
+++ b/README.md
@@ -24,7 +24,9 @@ to provide code folding base on the tree-sitter syntax tree.
     - [🔨 Supported languages](#🔨-supported-languages)
     - [⚖️ Indicators Mode](#⚖️-indicators-mode)
     - [📝 Summary](#📝-summary)
-    - [🔰 Contribution](#🔰-contribution)
+    - [🔰 Contribute](#🔰-contribute)
+        - [How to write a parser?](#how-to-write-a-parser)
+            - [Where can I look for tree-sitter 
node?](#where-can-i-look-for-tree-sitter-node)
 
 <!-- markdown-toc end -->
 
@@ -207,3 +209,12 @@ implementation. In the above example, `block` node is 
defined in the
 > Make sure you look into the correct repository. Repositories are managed
 > under 
 > [tree-sitter-langs](https://github.com/emacs-tree-sitter/tree-sitter-langs)'s
 > using the git submodule. Some tree-sitter module aren't using the latest 
 > version!
+
+#### How do I create the function for the corresponding node?
+
+Function takes 2 arguments, `node` and `offset`.
+
+* `node` - the targeting tree-sitter node; in this example, `block` will be the
+targeting node.
+* `offset` - (optiona) a cons consist of two integer. This is handy when you 
have
+similar rule with little of positioning adjustment.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]