Closed LandonSchropp closed 1 year ago
I really like the plugin. ThePrimeagen streams his work (on twitch) on refactor.nvim which goes into the same direction https://github.com/ThePrimeagen/refactoring.nvim and is based on the Refactoring book by Martin Fowler. Treesitter included.
A bit late, but I've been using this for a while and have no complaints: https://github.com/AckslD/nvim-trevJ.lua
trevJ
is fine for splitting lines but it can't join them.
Sure, I can use va}J, for example, but what if I don't want the spaces? No, gJ doesn't work since it doesn't remove the existing spaces.
Hello. I wrote a similar plugin using trееsitter. At the moment, it is not a complete replacement for splitjoin.vim (for example, there is no arrow function conversion in it), but in my cases it's work good. https://github.com/Wansmer/treesj
Hello. I wrote a similar plugin using trееsitter. At the moment, it is not a complete replacement for splitjoin.vim (for example, there is no arrow function conversion in it), but in my cases it's work good. https://github.com/Wansmer/treesj
This work should be enough too close this issue I believe
@searleser97 I agree. treesj is awesome!
What?
I love the splitjoin.vim plugin. It's been part of my daily workflow for years. However, there are times when it doesn't get things quite right, resulting in syntax errors. I'd love to see a new Neovim version of this plugin that uses treesitter for better accuracy.
Why?
This plugin saves a ton of time for daily development, making it easy to extend code to multiple lines or condense it to one line.
Potential existing implementations:
splitjoin.vim is already really solid. However, I think it could be better with treesitter.
*Potential pitfalls:*
One of the time-consuming aspects of the original splitjoin is working around individual language issues. Hopefully, treesitter would solve those problems.