According to the Vim fingerprint documentation , you can try the following to find out if it suits you.
Hand driving
If you change the current indentation of a line manually, Vim ignores the cindent for that line.
This can be annoying due to the frequency of this pattern in TypeScript.
Angle brackets
If you really want to backtrack as you type : use <:> .
This will give you padding without losing any of the cindent parts that you find useful.
Change cinkeys
It contains settings that affect the cindent parameter, by default it is:
"0{,0},0),:,0#,!^F,o,O,e"
But you might be lucky to change it to:
"0{,0},0),0#,!^F,o,O,e"
Ditch cindent
You can completely remove the c-style padding, but by removing this line:
setlocal cindent
I looked at several options, because the nature of Vim and the nature of code editing - you need to try the options to find out what suits you best.
source share