This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Created attachment 160100 [details] Wrong colors when varialbe directly in class When two variables or more are declared directly in the class (and not in a function), syntax highlighting doesn't work as expected (see attached screenshot). I don't know if it is part of the standard or not, but some code is written that way (for instance in the Aurelia framework: https://github.com/aurelia/framework/blob/master/src/framework-configuration.js#L117). Furthermore, the babel transpiller handles this code fine and VSCode doesn't report it as an error. Expected result: the code is parsed, function names are highlighted correctly and no error is reported. Sample code: export class Test { name = 'test'; test; constructor() { } } So, this code works fine: export class Test { name = 'test'; test; constructor() { } }
This is not standard ES6. Marking as enhancement.
This is ES7 feature. https://github.com/jeffmo/es-class-fields-and-static-properties
Fixed in trunk.
This works perfectly. Thanks. +1 for support of experimental ES7.