ESLint Rules in AppStudio

Can someone provide an example of how to disable a rule in the eslintRules Project Properties?

I’ve read through the links and tutorial provided in this post (ESLint Tutorial) but there’s no reference as to how to apply or override rules in the AppStudio Project Properties.

For example, I’m trying to switch off the “1:1: Expected linebreaks to be ‘CRLF’ but found ‘LF’. [Error/linebreak-style]” rule for starters since the 80% of the ESLint results box is showing this message.

What syntax is used in the eslintRules Properties to turn this rule off?

Thanks.

1 Like

I am interested in a solution too.
At https://eslint.org/docs/developer-guide/working-with-rules I found

If your rule is disallowing something, prefix it with no- such as no-eval for disallowing eval() and no-debugger for disallowing debugger .

So it seems that it should be something like no-linebreak-style. But this when entered does not work.

This needs a better solution than just adjusting the rule. We’ll try to get it into the next build.

1 Like

Meanwhile, you may use Validate Javascript
There are some style options: airbnb, eslint, google, standard and custom.
Using airbnb, I’ve got these warnings and errors for AppStudio Hello World (javascript sample):

You may also choose fo fix the code. It may help you reducing those 80% of linebreak-style warnings.

I’ve also tried to edit eslintrc.json (eslintRules Project Properties). No joy. It’s not working. I included several other rules and excluded linebreak-style rule. AppStudio keeps working with its default airbnb style, despite of new rules.

As George said, maybe in next build.
As I am at version 7.4.2.0, I will not be able to test next release. Probably, this is also the reason why it is not working for me now.

Thanks,

Adrian Nicolaiev

Linebreak messages in Windows fixed in 8.0.3.