naomi
naomi copied to clipboard
JSX symbols `>` and `/` break multiple cursors & selections
Is it possible to disable auto-close autocompletion?
-
I usually don't want to auto-close JSX tags.
-
any auto-close breaks multiple cursor editing, and turns into a single cursor at the first index.


This behavior is rather disruptive; I didn't realize it was coming from Naomi. Please do either disable it by default or at least document a way to disable it in settings.
This also breaks search (triggered by /
) in Vim mode. I think some additional "contexts" need to be added to this keybinding:
https://github.com/borela/naomi/blob/a1034a85cfc8e924e1e9a181765549fb890956a8/Default.sublime-keymap#L353-L378
The additional contexts are:
// to fix the <hr/>> issue above:
{ "key": "following_text", "operator": "not_regex_contains", "operand": ">" },
// to fix the multi-cursor issue:
{ "key": "num_selections", "operator": "equal", "operand": 1 },
// to fix the Vim mode issue
{ "key": "setting.command_mode", "operand": false },
Note: I haven't personally tested these, so they may not be exactly right, but I believe this is the gist of it.
Can I get a pointer on where to fix this? I can give it a stab.
@AlexKvazos my comment above outlines what I think are the correct fixes, but I haven't fully tested them myself.