titaniumappceleratorappcelerator-titaniumappcelerator-studio

Appcelerator Studio not detecting ES6 syntax


As of v6.1.0, Titanium supported ECMAScript 6: https://docs.appcelerator.com/platform/latest/?mobile=/guide/ES6_in_Titanium_SDK_6.1.0

I am currently using the official Accelerator Studio (based on Eclipse).

Unfortunately, it seems that the studio puts a red squiggly line underneath some ES6 code such as:

books.map( () => 1 );
let x = 5;

despite these being ES6 valid code.

This indicates to me that the IDE for some reason, JS still does not recognise ES6 syntax.

How can I update the studio so it detects ES6 syntax?


Solution

  • In the page you linked to it says:

    Studio does not yet support ES6 grammar and may improperly mark such code as having errors: TISTUD-8764

    Also note that according to that doc, there are additional limitations to using ES6, and you may also have to make additional changes to your code to use ES6. See the part under Great, how do I use it now?