How can I create a VS Code keyboard shortcut to change a camel-case string to sentence-case?

In VScode I need one shortcut which can split one single string (camel-case) into words with space(s).
e.g.

getCheckoutCartHelper

desired output:

Get checkout cart helper

Tried to create shortcut in key-binding but nothing.

>Solution :

There is a VS Code extension called "change-case". Install this extension. In VS Code, open the Shortcut settings with "Shift + Ctrl + P" and type in "Preferences: Open Keyboard Shortcuts". There you can search the command "extension.changeCase.sentence" and bind it to a shortcut.

Regards

Leave a Reply