WPCS with Visual Studio Code
After setting the WPCS well, if we want to format the code with shortcut key according to WordPress coding standard, we’ll need to follow the instruction below –
- Install the PHPCBF extension.
- Set the phpcbf executable path.
- Set the shortcut key.
My user settings are like –1234567"phpcbf.standard": "WordPress","phpcbf.executablePath": "~/.composer/vendor/bin/phpcbf","phpcbf.onsave": true