The syntax of model elements which contains JavaScript functions, like JSFunction, JSFileLibrary, JSConditionExport, JSNewContextExport or JSPostprocessExport, can be checked by the M2M Engine.
To proceed, right-click on the elements in the browser, and click on M2M | JavaScript syntax checker:
The syntax check result is displayed on the Rhapsody console: