Comment Toggle Trick Hero Image

The Comment Toggle Trick

This trick below can be used to toggle between two sets of code, with one symbol in the code with no additional short-keys to learn, and no tool dependencies!

//* /*
someCode(); someCode();
// //
someOtherCode(); someOtherCode();
/// ///

Here is a version for simply commenting code in and out:

//*
someCode();
//*/

Deactivated / commented out:

/*
someCode();
//*/