Questions tagged [eslint]
The eslint tag has no usage guidance.
12
questions
0
votes
1
answer
136
views
ESLint not recognizing files in non-standard folder structure
Installing ESLint and receiving the following error when issuing the command npm run lint:
Oops! Something went wrong! :(
ESLint: 8.57.0
No files matching the pattern "**/aura/**/*.js" ...
2
votes
0
answers
89
views
Cannot lint vs LWS (Lightning web security) standards with eslint, missing config extension
We are in the process of executing the ESLint rules for enabling Lightning Web Security (LWC). We are following the below document to install the ESLint, which is working fine with the LWC component ...
1
vote
0
answers
58
views
ESLint/prettier conflict when using cumulusci namespace placeholder in Apex
I am getting the below error when I run npm run prettier and when I commit (since I have a husky hook) a couple of Apex classes that use namespace placeholders .
Error: Found punctuation symbol or ...
0
votes
1
answer
476
views
Parsing error: Unexpected token day
When trying to commit the eslint precommit is running and getting the error: 3:9 error Parsing error: Unexpected token day and prevent the commit from happen
I'm executing this example commit:
PS C:\...
3
votes
1
answer
3k
views
@api setter invalid reassignment of public property
I am using @api setter to update variable and I receive "invalid reassignment of public property". How can I fix it? I thought problem with my logic and removed everything and nothing is ...
1
vote
1
answer
33
views
Terminal error (esLint) related to hasOwnProperty when compiling
Even the code working good… i am getting this error on terminal.
if (response.product.hasOwnProperty('availabilityForPickup') {
//Do something...
}
Do not access Object.prototype method '...
0
votes
1
answer
660
views
Apex (Salesforce) - How to silence "File ignored because of a matching ignore pattern"
I am trying to remove all errors related to eslint and I successfully did it by adding /force-app/main/default/ into my .eslintignore file.
But the problem is, now I get this warning:
File ignored ...
0
votes
0
answers
512
views
ESlint and Salesforce
Does anyone know how to properly configure eslint config file and where to put it in Salesforce.
I need to disable some rules and I found that, for example, if I want to disable "ApexDoc" ...
1
vote
1
answer
1k
views
How to resolve @lwc/lwc/no-unknown-wire-adapters linting errors in LWC?
In a new project I am getting eslint errors like:
6:10 error "getObjectInfo" from "lightning/uiObjectInfoApi" is not a known adapter @lwc/lwc/no-unknown-wire-adapters
The ...
0
votes
1
answer
84
views
What values to put into npm init when following workaround instructions to get eslint working in sfdx project?
I'm experiencing the same problem as the poser of this question:
Why is ESLint not working properly for Lightning Web Components in VS Code and how to make it work?
One of the steps is to run npm init ...
5
votes
2
answers
8k
views
Why is ESLint not working properly for Lightning Web Components in VS Code and how to make it work?
I'm trying to set up an environment to play around with LWCs. While doing a Analyze Your Code and Deploy It to Your Org unit from the Set Up Your Lightning Web Components Developer Tools module on ...
1
vote
0
answers
204
views
LWC eslint rule [closed]
I am in VSCODE and trying to set eslint rule for LWC using https://github.com/salesforce/eslint-plugin-lwc I am unable to set it up properly and lint rules are not firing. Can anybody help me here who ...