# wildfire.nvim **Repository Path**: zaboom/wildfire.nvim ## Basic Information - **Project Name**: wildfire.nvim - **Description**: No description available - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2023-12-17 - **Last Updated**: 2023-12-17 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 🔥Wildfire.nvim: Wildfire burns treesitter🌲 A modern successor to [wildfire.vim](https://github.com/gcmt/wildfire.vim), empowered with the superpower of treesitter.
## Highlights - ⚡ Smartly select the **inner** part of texts - ⚫ **count prefix** - 🌳 **Treesitter Integration** ## Motivation I’ve found that treesitter’s [`incremental_selection`](https://www.reddit.com/r/neovim/comments/r10llx/the_most_amazing_builtin_feature_nobody_ever/) is particularly handy for text selection. It often allows for selecting the desired text with fewer keystrokes compared to a well-configured wildfire.vim, all without the need to set up intricate text objects. However, since treesitter relies solely on AST for incremental selection, it tends to be overly **aggressive** for surrounds. In such case, I have to revert to using text objects for selection, which is annoyed and tripped me up in practical use. On the other hand, treesitter doesn’t support the `count prefix(vim.v.count)`, which can make it somewhat cumbersome when dealing with longer ranges. Its implementation is also a bit buggy, as you might select an area within the same range(see below). > A picture is worth a thousand words  ## Usage The usage is almost the same as [wildfire.vim](https://github.com/gcmt/wildfire.vim) and [`incremental_selection`](https://www.reddit.com/r/neovim/comments/r10llx/the_most_amazing_builtin_feature_nobody_ever/), You can check out their introduction to get a sense of it. - `CR` Init selection and do incremental selection if you have initilized (so just keep pressing `CR`). - `BS` Decremental selection. - `NUM-CR` Accelerate selection with count prefix. This plugin offers a streamlined method for text selection, freeing you from the hassle of configuring and remembering intricate text objects. Plus, initiating this plugin with `CR` seamlessly transitions you into visual mode. This means you can still harness the power of your preferred text objects without any extra keystrokes (like `v-i-b` or `CR-i-b`). Beyond the basic actions such as yank(`CR`), delete(`d`), and change (`c`), here are a few other awesome tricks up its sleeve: - Partially format with: textDocument/rangeFormatting - Narrow down regions using: [nag.nvim](https://github.com/haolian9/nag.nvim) - Adding surrounding pairs via: [nvim-surround](https://github.com/kylechui/nvim-surround) - Comments with [comment.nvim](https://github.com/numToStr/Comment.nvim)