I was an Emacs user for many years. I used it to write my papers and dissertation (AUCTeX mode was great), and a huge amount of code.

I switched to Vim, and later to NeoVim. I'd highly recommend it.

It's scriptable, and these days is scriptable in multiple "real" programming languages. It took some getting used to, but I found myself going faster in vim than I ever did in Emacs.

You might find https://vim-adventures.com/ fun for learning some of the basics. In particular, it's worth spending time learning the motion commands "in the small", because you'll spend a lot of time using them. For instance:

t (up to character) and f (up to and including character)

i( (inside parens, works with [ or < or ", or p for paragraph)

a( (same thing but includes the delimiters).

Things like that are extremely worth learning, in part because they're the "nouns" in vim's verb-noun editing model, so you'll use them in many different commands.