Syntax
Expand Minimize

Syntax

Syntax rules check the JavaScript code for syntax errors.

Index

Rule Description Type Severity
SPC2389100: Strict-mode does not allow duplicate argument names Strict-mode does not allow duplicate argument names JavaScriptFile CriticalError
SPC2389101: Strict-mode does not allow certain variable names Strict-mode does not allow certain variable names JavaScriptFile CriticalError
SPC2389102: Strict-mode does not allow certain function names Strict-mode does not allow certain function names JavaScriptFile CriticalError
SPC2389103: Strict-mode does not allow duplicate property names Strict-mode does not allow duplicate property names JavaScriptFile CriticalError
SPC2389104: Strict-mode does not allow assignment to certain variables Strict-mode does not allow assignment to certain variables JavaScriptFile CriticalError
SPC2389105: Strict-mode does not allow ++ or -- on certain objects Strict-mode does not allow ++ or -- on certain objects JavaScriptFile CriticalError
SPC2389106: Strict-mode does not allow certain delete operands Strict-mode does not allow certain delete operands JavaScriptFile CriticalError
SPC2389107: Strict-mode does not allow certain argument names Strict-mode does not allow certain argument names JavaScriptFile CriticalError
SPC2389108: Assignment to constant Assignment to constant JavaScriptFile CriticalError
SPC2389109: String literal is not safe for inline String literal is not safe for inline JavaScriptFile CriticalError
SPC2389110: Strict-mode does not allow assignment to undefined variables Strict-mode does not allow assignment to undefined variables JavaScriptFile CriticalError
SPC2389111: End of file encountered before function is properly closed End of file encountered before function is properly closed JavaScriptFile CriticalError
SPC2389112: Expected ///#ENDIF directive Expected ///#ENDIF directive JavaScriptFile CriticalError
SPC2389113: Expected ///#ENDDEBUG directive Expected ///#ENDDEBUG directive JavaScriptFile CriticalError
SPC2389114: Invalid numeric literal Invalid numeric literal JavaScriptFile CriticalError
SPC2389115: Suspect equality comparison Suspect equality comparison JavaScriptFile CriticalError
SPC2389116: Strict-mode does not allow certain catch error binding names Strict-mode does not allow certain catch error binding names JavaScriptFile CriticalError
SPC2389117: Binding patterns in var statements require initializer Binding patterns in var statements require initializer JavaScriptFile CriticalError
SPC2389118: Implicit object property name must be identifier Implicit object property name must be identifier JavaScriptFile CriticalError
SPC2389119: Setter method must have a single format argument Setter method must have a single format argument JavaScriptFile CriticalError
SPC2389120: Rest parameter can only be last parameter Rest parameter can only be last parameter JavaScriptFile CriticalError
SPC2389121: Unable to convert to binding syntax Unable to convert to binding syntax JavaScriptFile CriticalError
SPC2389122: Unable to convert from binding syntax Unable to convert from binding syntax JavaScriptFile CriticalError
SPC2389123: Invalid binding syntax Invalid binding syntax JavaScriptFile CriticalError
SPC2389124: Methods not allowed in object literal bindings Methods not allowed in object literal bindings JavaScriptFile CriticalError
SPC2389125: Expected for or if keyword Expected for or if keyword JavaScriptFile CriticalError
SPC2389126: Expected class element Expected class element JavaScriptFile CriticalError
SPC2389127: Duplicate class element name Duplicate class element name JavaScriptFile CriticalError
SPC2389128: Class constructor must be regular method Class constructor must be regular method JavaScriptFile CriticalError
SPC2389129: Class static method cannot be named 'prototype' Class static method cannot be named 'prototype' JavaScriptFile CriticalError
SPC2389130: Expected binding Expected binding JavaScriptFile CriticalError
SPC2389131: Multiple default exports Multiple default exports JavaScriptFile CriticalError
SPC2389132: Import statement must include module name Import statement must include module name JavaScriptFile CriticalError
SPC2389133: Duplicate module declaration Duplicate module declaration JavaScriptFile CriticalError
SPC2389134: Imported module has no default export Imported module has no default export JavaScriptFile CriticalError
SPC2389135: Expected 'from' Expected 'from' JavaScriptFile CriticalError
SPC2389136: Expected string literal Expected string literal JavaScriptFile CriticalError
SPC2389137: Expected specifier set Expected specifier set JavaScriptFile CriticalError
SPC2389138: Arrow functions cannot be constructors Arrow functions cannot be constructors JavaScriptFile CriticalError
SPC2389139: Application Error Application Error JavaScriptFile CriticalError
SPC2389140: No Source Error No Source Error JavaScriptFile CriticalError
SPC238950: Could not parse JavaScript code Could not parse JavaScript code JavaScriptFile CriticalError
SPC238951: Syntax error Syntax error JavaScriptFile CriticalError
SPC238952: Expected ':' Expected ':' JavaScriptFile CriticalError
SPC238953: Expected ';' Expected ';' JavaScriptFile CriticalError
SPC238954: Expected '(' Expected '(' JavaScriptFile CriticalError
SPC238955: Expected ')' Expected ')' JavaScriptFile CriticalError
SPC238956: Expected ']' Expected ']' JavaScriptFile CriticalError
SPC238957: Expected '{' Expected '{' JavaScriptFile CriticalError
SPC238958: Expected '}' Expected '}' JavaScriptFile CriticalError
SPC238959: Expected identifier Expected identifier JavaScriptFile CriticalError
SPC238960: Expected '=' Expected '=' JavaScriptFile CriticalError
SPC238961: Illegal assignment Illegal assignment JavaScriptFile CriticalError
SPC238962: Syntax error in regular expression Syntax error in regular expression JavaScriptFile CriticalError
SPC238963: Invalid character Invalid character JavaScriptFile CriticalError
SPC238964: Unterminated string constant Unterminated string constant JavaScriptFile CriticalError
SPC238965: Unterminated comment Unterminated comment JavaScriptFile CriticalError
SPC238966: 'return' statement outside of function 'return' statement outside of function JavaScriptFile CriticalError
SPC238967: Can't have 'break' outside of loop Can't have 'break' outside of loop JavaScriptFile CriticalError
SPC238968: Can't have 'continue' outside of loop Can't have 'continue' outside of loop JavaScriptFile CriticalError
SPC238969: unused label unused label JavaScriptFile CriticalError
SPC238970: Expected hexadecimal digit Expected hexadecimal digit JavaScriptFile CriticalError
SPC238971: Expected 'while' Expected 'while' JavaScriptFile CriticalError
SPC238972: Label redefined Label redefined JavaScriptFile CriticalError
SPC238973: Label not found Label not found JavaScriptFile CriticalError
SPC238974: 'default' can only appear once in a 'switch' statement 'default' can only appear once in a 'switch' statement JavaScriptFile CriticalError
SPC238975: Expected identifier or string Expected identifier or string JavaScriptFile CriticalError
SPC238976: Expected '@end' Expected '@end' JavaScriptFile CriticalError
SPC238977: Conditional compilation is turned off Conditional compilation is turned off JavaScriptFile CriticalError
SPC238978: Expected 'catch' Expected 'catch' JavaScriptFile CriticalError
SPC238979: Unmatched 'else'; no 'if' defined Unmatched 'else'; no 'if' defined JavaScriptFile CriticalError
SPC238980: Expected ',' Expected ',' JavaScriptFile CriticalError
SPC238981: Missing 'case' or 'default' statement Missing 'case' or 'default' statement JavaScriptFile CriticalError
SPC238982: Unmatched '@end'; no '@if' defined Unmatched '@end'; no '@if' defined JavaScriptFile CriticalError
SPC238983: Unmatched '@else'; no '@if' defined Unmatched '@else'; no '@if' defined JavaScriptFile CriticalError
SPC238984: Unmatched '@elif'; no '@if' defined Unmatched '@elif'; no '@if' defined JavaScriptFile CriticalError
SPC238985: Expecting more source characters Expecting more source characters JavaScriptFile CriticalError
SPC238986: Variable has not been declared Variable has not been declared JavaScriptFile CriticalError
SPC238987: Expected ',' or ')' Expected ',' or ')' JavaScriptFile CriticalError
SPC238988: Expected ',' or ']' Expected ',' or ']' JavaScriptFile CriticalError
SPC238989: Expected expression Expected expression JavaScriptFile CriticalError
SPC238990: Unexpected ';' Unexpected ';' JavaScriptFile CriticalError
SPC238991: Too many tokens have been skipped in the process of recovering from errors. The file may not be a JScript.NET file Too many tokens have been skipped in the process of recovering from errors. The file may not be a JScript.NET file JavaScriptFile CriticalError
SPC238992: Did you intend to have an empty statement for this branch of the if statement? Did you intend to have an empty statement for this branch of the if statement? JavaScriptFile CriticalError
SPC238993: A variable argument list must be the last argument A variable argument list must be the last argument JavaScriptFile CriticalError
SPC238994: Function expression expected Function expression expected JavaScriptFile CriticalError
SPC238995: JSParser Exception JSParser Exception JavaScriptFile CriticalError
SPC238996: Resource reference must be single constant value Resource reference must be single constant value JavaScriptFile CriticalError
SPC238997: Conditiona compilation structure too complex Conditiona compilation structure too complex JavaScriptFile CriticalError
SPC238998: Unterminated ASP.NET block Unterminated ASP.NET block JavaScriptFile CriticalError
SPC238999: Strict-mode does not allow with-statements Strict-mode does not allow with-statements JavaScriptFile CriticalError
Disclaimer: The views and opinions expressed in this documentation and in SPCAF do not necessarily reflect the opinions and recommendations of Microsoft or any member of Microsoft. SPCAF and RENCORE are registered trademarks of RENCORE AB. All other trademarks, service marks, collective marks, copyrights, registered names, and marks used or cited by this documentation are the property of their respective owners.