Which is Better Flash.nvim OR Leap.nvim?

  Рет қаралды 7,350

Andrew Courter

Andrew Courter

Күн бұрын

In this video I go over installation and usage of the flash.nvim plugin and how you can quickly jump to different locations within a buffer or across window splits in Neovim. I compare this to leap.nvim and decide on which provides the best functionality and the best default usage for jumping to exact locations.
Companion Article: / which-is-better-flash-...
My Neovim Config: github.com/exosyphon/nvim
Leap.nvim: github.com/ggandor/leap.nvim
Flash.nvim: github.com/folke/flash.nvim
Join the channel to get access to perks:
/ @ascourter
Ask me a question!
andrewcourter.com/services
Twitter: / exosyphon
Website: andrewcourter.com
Twitch: / exosyphon
Gear:
Mic: amzn.to/40GUGFg
Mic Interface: amzn.to/3YGxaGE
Mic preamp: amzn.to/3XtBXtY
Webcam: amzn.to/3OEOZRU
Boom Arm: amzn.to/3qLr0GE
Vissles (VS II switches): vissles.com/?ref=69zn8aei20 - Coupon Code for $5 off: ANDREWCOURTER
IQUNIX F97 (TTC ACE switches): iqunix.store/collections/f97-...
Free Stock Footage by videezy.com/
🎵 Music
Pacific Hike - Silent Partner | Royalty Free Music - No Copyright Music
⏰ Timestamps
0:00 Intro
0:31 Install flash.nvim
1:47 require("flash").jump()
3:40 require("flash").treesitter()
4:23 require("flash").remote()
5:34 require("flash").treesitter_search()
6:33 require("flash").toggle()
7:46 Enhanced f and t
9:32 Flash.nvim vs Leap.nvim
11:06 Outro
#neovim #coding #softwareengineer

Пікірлер: 56
@ascourter
@ascourter 29 күн бұрын
Do you use flash.nvim?
@sp3ctum
@sp3ctum 29 күн бұрын
I really tried to like it, but a long time ago I got used to, I think, easymotion. I wasn't able to shake the habit and now I use hop.nvim. I guess I'm too set in my ways 😄
@ZiRo815
@ZiRo815 29 күн бұрын
flash works how I want it to. I don’t want to type a specific number of letters. I just want to look at where I want to go, press a letter and then the red letter and boom I’m there. Leap’s need for 2 letter minimum jars me, especially around symbols.
@ghostsssssss4884
@ghostsssssss4884 29 күн бұрын
Been using it for a while and it keeps improving my workflow(no more 13j etc). I would love to get used to the remote operations but somehow the mental overhead is too big and i spend more time thinking bout the commands than it would take me to do it regularly. Do you experience similar issues with plugins you would like to use more but dont?
@ascourter
@ascourter 29 күн бұрын
@@ghostsssssss4884 I definitely experience this with different plugins. If you don't use the plugin at all then could be an indicator of having too many but sometimes your workflow just changes over time.
@ekkyarmandi
@ekkyarmandi 23 күн бұрын
I've been using flash for a couple of months now. flash.nvim resolved my search workflows, but your video covers a feature I do not know exists, it's really helpful!
@crusader_
@crusader_ 12 күн бұрын
Just when I was scratching my head in confusion whether to choose leap or flash. Thank you!
@ascourter
@ascourter 11 күн бұрын
Glad I could help!
@paolocabaleiro
@paolocabaleiro 29 күн бұрын
I remember back when I suggested you should use Flash, glad to see this video now :D You have been missed on Twitch land, hope to see you there one day.
@ascourter
@ascourter 29 күн бұрын
Thanks for suggesting it! I finally got around to trying it out. Hopefully I can get back into Twitch again, maybe once I can get my kids to bed earlier 😂
@Hoopsters35
@Hoopsters35 29 күн бұрын
At 3:00 you mention that flash giving one keybind to jump in any window is key to you. If anyone is wondering how to do that in leap, you can use require('leap').leap({target_windows = {winid1, winid2}}) to target as many windows as you'd like. Combine this with require('leap.util').get_enterable_windows() which gives all visible windows except the current one, and vim.api.nvim_get_current_win() and you can jump to anything on the screen with one keybind
@ascourter
@ascourter 29 күн бұрын
Thanks for sharing this!
@liamwoodleigh
@liamwoodleigh 25 күн бұрын
Thanks for this! Could you please give an example of it as lazy config? 👀
@rwz
@rwz 24 күн бұрын
i was using leap, but the 2 char behavior was throwing me too often, now with flash it is very intuitive. thanks!
@NormalNvim
@NormalNvim 29 күн бұрын
Hop is pretty amazing too! Love the aesthetic.
@ascourter
@ascourter 29 күн бұрын
Sweet. I'm excited to give it a try next!
@lpanebr
@lpanebr 29 күн бұрын
I use to like those but then I felt they messed with my vanilla way of doing things with additional overhead. I'm currently loving the precognition plugin that actually helps you use vanilla mappings by adding jump hints in virtual text.
@atxorsatti
@atxorsatti 29 күн бұрын
Honestly I love this extension, and that exactly why I stopped using it. I used it almost exclusively, for every movement, and it came to a point that I didn't know some native vim movement s. I had to stop using it in order to learn them.
@ascourter
@ascourter 29 күн бұрын
Oh that's really interesting. I could definitely see being too reliant on it. Thanks for sharing!
@Lambdaphile
@Lambdaphile 18 күн бұрын
This is the best Vim channel
@ascourter
@ascourter 18 күн бұрын
Thank you! That's very kind
@mvargasmoran
@mvargasmoran 28 күн бұрын
I've tried and yeeted all of this plugins, including Emacs Ace Jump Mode, way back in 2010~2012. I far prefer to use the / or incremental search.
@ascourter
@ascourter 28 күн бұрын
Haha the idea of yeeting a plugin is hilarious. Maybe this is where we will all end up eventually.
@mvargasmoran
@mvargasmoran 28 күн бұрын
@@ascourter it think it's stages in life, getting all the plugins, then ditching all the plugins. it happens.
@jieli-mw7ox
@jieli-mw7ox 21 күн бұрын
nice
@Petrovich2049
@Petrovich2049 9 күн бұрын
I think both of these plugins offer an illusion of efficiency. Yes you may save few keystrokes, but you need to think more about how and where do you want to move? Should you use vim motions or the plugin? And while you are using the plugin, you aren't perfecting vim motions. How hard is it to write say 12j + whatever horizontal jump? Or search for something then just press n free times to skip to the one you want?
@ascourter
@ascourter 8 күн бұрын
I think this is a really fair question. Some folks want to get better at default vim bindings and others want to customize and use different plugins. I do think there is some potential efficiency gains with using either of these plugins but you need to learn and develop the muscle memory for that efficiency. One of the best features of Neovim is that everyone can choose what they prefer and customize the editor. This decision is also not set in stone, I have seen a couple comments of people who said they relied on these plugins too much and went back to using built in vim motions. Whichever you choose, have fun and continue learning!
@muizzyranking
@muizzyranking 29 күн бұрын
I don't like enhances f/t motion from flash, thats why i use leap + flit.
@ascourter
@ascourter 20 күн бұрын
Yeah, I'd say you could disable it but it looks like there is an open issue currently. github.com/folke/flash.nvim/issues/329
@blbezcc
@blbezcc 29 күн бұрын
Don't you miss the s and S keybinds you have overwritten with it? I do, and I'm searching for better one letter keybind to use instead.
@ascourter
@ascourter 29 күн бұрын
I have found other motions to replace s and S for me (e.g. cc). How are you using s and S?
@blbezcc
@blbezcc 28 күн бұрын
@@ascourter wow, I didn't know about cc. Thanks. That solves the S problem and for s, I just found out that equivalent is "cl" (c and lowercase L).
@cody_codes_youtube
@cody_codes_youtube 29 күн бұрын
IM NOT FIRST BECAUSE YOU PUBLISHED AT 7:45AM YOU MANIAC
@ascourter
@ascourter 29 күн бұрын
Half the day is already over! 😂
@adrianscarlett
@adrianscarlett 29 күн бұрын
You should move to a different timezone...
@shubhampawar7921
@shubhampawar7921 27 күн бұрын
Can i disable flash.nvim for f & t, i dont think its useful
@ascourter
@ascourter 26 күн бұрын
You should be able to disable it but it looks like there is an open issue currently. Check out this page: github.com/folke/flash.nvim/issues/329
@seppotaalasmaa3404
@seppotaalasmaa3404 20 күн бұрын
Why can't we just use markers?
@ascourter
@ascourter 19 күн бұрын
Haha I think you could if that's what you'd like. You'd have to set a mark somewhere before you were able to jump there is a problem for me. Let me know if you use marks to jump around and how you use them.
@Gskvj
@Gskvj 29 күн бұрын
I'm not quite sure how this might necessarily be better than Harpoon
@ascourter
@ascourter 29 күн бұрын
I believe you jump between buffers with harpoon, this is to jump to locations within the same buffer.
@ZiRo815
@ZiRo815 29 күн бұрын
I sincerely hope this was just someone trolling.
@MrEternalFool
@MrEternalFool 29 күн бұрын
None actually, all cause a context change. You screen changes, you then have to type a random character or maybe two. Instead just longpress j, k to go the correct line number and b,w or f to get to where you want. Decrease key repeat time to make this faster. This doesn't cause a brain context change and you can focus on your code instead of random flashing characters.
@ascourter
@ascourter 29 күн бұрын
This is what's great about Neovim, you can use what makes sense to you as a user.
@hechuan5075
@hechuan5075 29 күн бұрын
having to repeatedly hitting b or B, j or k even relative line jumping was too slow and exactly why i switched to Flaah, lol
@no_name4796
@no_name4796 29 күн бұрын
Yeah. Also / works pretty fine most of the times. And if it doesn't, i just manually navigate. But yeah, i hate having to think about what i do (except when i do macros, which in fact i do only if i want to have some fun, or have big changes to make and a good macro is worth it)
@no_name4796
@no_name4796 29 күн бұрын
Also: i tend to use the defaults as much as possible. This for 3 reasons: - i am lazy - defaults are mantained by neovim devs, so they will always work (unlike plugin stuff which may break, get deprecated or who knows what) - using defaults means that if i fuck up and need to run neovim without plugins, or on a different computer, then my muscle memory will still be valid
@user-zl6om6kh9s
@user-zl6om6kh9s 29 күн бұрын
You don't mention leap.nvim most useful feature: instantly jump to next match without type a char, that's the bonus of 2 char search
@ascourter
@ascourter 29 күн бұрын
Ah I did forget this. I trigger this case so little that I forget about it.
@RuanSilva-kk1gq
@RuanSilva-kk1gq 29 күн бұрын
I prefere hop.nvim
@ascourter
@ascourter 29 күн бұрын
Nice. This one is next up! What do you like best?
@garctin
@garctin 27 күн бұрын
I tried flash.nvim when it was added to LazyVim. But coming from leap.nvim I always felt lost. It was unintuitive to me. So I'm back on leap.nvim.
@rodelias9378
@rodelias9378 27 күн бұрын
Great video. I think it's time for me to move from leap.nvim to flash.nvim
@ascourter
@ascourter 27 күн бұрын
Definitely worth a try. There have been several people who say hop.nvim is even better so that's on my list to check out next!
Code Folding in Neovim
11:22
Andrew Courter
Рет қаралды 13 М.
버블티로 체감되는 요즘 물가
00:16
진영민yeongmin
Рет қаралды 39 МЛН
A pack of chips with a surprise 🤣😍❤️ #demariki
00:14
Demariki
Рет қаралды 48 МЛН
Reacting to Controversial Opinions of Software Engineers
9:18
Fireship
Рет қаралды 2 МЛН
Fast Jumping in Neovim with Leap.nvim
7:10
Andrew Courter
Рет қаралды 4,2 М.
98% Cloud Cost Saved By Writing Our Own Database
21:45
ThePrimeTime
Рет қаралды 308 М.
This Should Have Been In CSS Years Ago
1:57
Dev Dive In
Рет қаралды 3,4 М.
Cool Tools I’ve Been Using Lately
23:11
Theo - t3․gg
Рет қаралды 179 М.
We can now write scripts using these languages, but is it worth it?
8:28
Why oil.nvim is the best directory plugin
9:12
Andrew Courter
Рет қаралды 22 М.
Why Neovim nerds are so obsessed with the terminal
6:44
Joshua Morony
Рет қаралды 77 М.
NIX OS: the BEST package manager on the MOST SOLID Linux distribution
17:08
The Linux Experiment
Рет қаралды 302 М.
The Best Oil.nvim Configuration
7:15
Andrew Courter
Рет қаралды 7 М.
Secret Wireless charger 😱 #shorts
0:28
Mr DegrEE
Рет қаралды 705 М.
Разряженный iPhone может больше Android
0:34