Search code examples
javascriptif-statementeval

Javascript syntax semicolon


I have this JavaScript code which I want to know what exactly is happening with the semicolon after the {.

if(buttonid=='save') {

    if (eval(formSaveCallback)) {;  //what is the use of this semicolon

        //Some code

    }

}

Solution

  • What's the use of ; in each and every line of code? The answer is the same for this too.