|
From: | Karan Ahlawat |
Subject: | Setting up indent-on-type in a treesit based major-mode |
Date: | Mon, 21 Oct 2024 00:39:41 +0530 |
User-agent: | Mozilla Thunderbird |
Hello,Today I was using ruby-ts-mode and found out that it can indent some keywords as soon as they're typed out fully (example, when inside a case block). I'd love to implement such a feature in scala-ts-mode, so I looked at the source code, but could not see anything special it might be doing besides simple treesit indent setup.
So, how does it exactly achieve this indent-on-type behavior (I can see the matcher being called if I set treesit--indent-verbose to t), and how could I reproduce this in my own major-mode?
Thanks, Karan
[Prev in Thread] | Current Thread | [Next in Thread] |