Switch variables, booleans and commonly used keywords
Default Keymaps | Commands | |
---|---|---|
Cycle Forward | Alt+a | K-O-M Cycle Forward |
Cycle Backward | Alt+x | K-O-M Cycle Backward |
The default keybindings are inspired by VIM's add Ctrl-a and subtract Ctrl-x.
Of course , you can remap them to your preference.
Settings are accessible via the GUI settings and your settings.json
file.
Choose whether you want to use the default keywords and add custom cycle groups.
Simply create a custom keyword cycle group by adding it as an array of strings to your settings.json
.
E.g., if one of the groups you want to add should cycle through foo
/ bar
/ baz
, it would be implemented like shown below. To add another group just separate it with a comma.
"keyword-o-mat.customKeywords": [
["foo", "bar", "baz"],
["veggies", "fruits", "berries"]
],
Rotate symbols* and words that are in one row |
---|
&& , || |
and , or |
true , false |
if , else |
YES , NO |
yes , no |
on , off |
running , stopped |
const , let |
private , protected , public |
push , pull |
div , p , span |
max , min |
ul , ol |
class , id |
px , % , em |
left , right |
top , bottom |
margin , padding |
height , width |
absolute , relative |
h1 , h2 , h3 , h4 , h5 , h6 |
png , jpg , gif |
linear , radial |
horizontal , vertical |
show , hide |
mouseover , mouseout |
mouseenter , mouseleave |
add , remove |
up , down |
before , after |
slow , fast |
small , large |
even , odd |
inside , outside |
above , below |
include , require |
Time , Date |
present , blank |
while , until |
only , except |
create , update |
new , edit |
get , post , put , patch |
one , two , three , four , five |
first , second , third , forth , fifth , last |
primary , secondary , tertiary , quaternary , quinary |
Monday , Tuesday , Wednesday , Thursday , Friday , Saturday , Sunday |
TODO , DOING , DONE , CANCELED |
NOW , LATER |
* A visual selection is required when the cycle element is a:
- Word separated by a hyphen, e.g., element-
one
- Symbol like
&&
It is sufficient to place the cursor above the cycle element when it is a:
- Word surrounded by spaces, parentheses, or double quotes
- Users can define custom keyword cycle groups in their
settings.json
- Add option to disable default keywords
- Initial release
- User created keyword groups
- Option to disable default keywords
- Language(filetype) specific keywords
- Advanced user options
Similar extensions and projects that served as an inspiration.