Announcement

Collapse
No announcement yet.

ES6 Syntax Highlighting

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • ES6 Syntax Highlighting

    Any chance that with the 3.7 addition of the ES6 Javascript update that we'll also get a Javascript syntax highlighting to match the new capabilities?

    Any way to implement this manually?

  • #2
    Also, I don't seem to be able to use all of the expected ES6 functionality. Has anyone asked this at one of the developer Q&A sessions?

    Arrow functions [yes]
    Use of let and const [yes]
    Template literals [no]
    Default parameters in functions [no]


    When I try to use a template literal in a javascript filter/transform like this:
    logger.error(`testing`);
    I get this validation error:
    Error in connector "sourceConnector" at filter rule 0 ("null"):
    Error on line 12: illegal character: ` (a0fce48c-3f3c-4e1b-b04a-af285ac058ec#12).

    When I try to create the following function:
    function testFunc(a, b = 3) {
    return a+b;
    }
    logger.error(testFunc(4,6));
    logger.error(testFunc(3));
    I get this error:
    Error in connector "sourceConnector" at filter rule 0 ("null"):
    Error on line 12: missing ) after formal parameters (801ba5ac-9ee5-46d0-9ca4-ec0277e5e68b#12).
    Last edited by akathol; 03-08-2019, 08:24 AM.

    Comment


    • #3
      Seems Rhino does not support the Template literals.
      X Connections
      https://documentor.email
      https://www.x-connections.com

      Comment

      Working...
      X