Skip to main content
JoseAlvira
Known Participant
June 29, 2020
Question

eslint ES6 and public class fields

  • June 29, 2020
  • 1 reply
  • 513 views

I have been unable to set eslint to recognize public class fields.

 

I set ecmaversion to 6 in the eslintrc.js, and I also tried deleting the file and set version to 6 in the site configuration and I still get an error with code like:

 

class MyClass {

var1 = 5

...

Any idea?

 

This topic has been closed for replies.

1 reply

Nancy OShea
Community Expert
Community Expert
June 29, 2020

JS Linters are rarely perfect.  Take the good with the bad.

https://jslint.com/help.html

 

 

Nancy O'Shea— Product User & Community Expert