js-beautify

How do you add a space after the keyword "function" - JS Beautify


trying to make it so that the package picks up this:

function(){}

and corrects it to:

function () {

}

Solution

  • Try adding this line in the js block of your .jsbeautifyrc file

        "space_after_anon_function": true