Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[naming-convention] support the abstract accessor #8242

Closed
4 tasks done
arka1002 opened this issue Jan 12, 2024 · 1 comment
Closed
4 tasks done

[naming-convention] support the abstract accessor #8242

arka1002 opened this issue Jan 12, 2024 · 1 comment
Labels
accepting prs Go ahead, send a pull request that resolves this issue enhancement: plugin rule option New rule option for an existing eslint-plugin rule package: eslint-plugin Issues related to @typescript-eslint/eslint-plugin

Comments

@arka1002
Copy link
Contributor

Before You File a Bug Report Please Confirm You Have Done The Following...

  • I have tried restarting my IDE and the issue persists.
  • I have updated to the latest version of the packages.
  • I have searched for related issues and found none that matched my issue.
  • I have read the FAQ and my problem is not listed.

Playground Link

https://typescript-eslint.io/play/#ts=5.1.6&fileType=.tsx&code=IYIwzgLgTsDGEAJYBthjAgkgcwHYHsoBTAEwQG8BYAKAQVEhngWyMQGVoBLeABTVjBkAYTREAFAEoAXAkZdc2ANw0AvjSA&eslintrc=N4KABGBEBOCuA2BTAzpAXGUEKQAIBcBPABxQGNoBLY-AWhXkoDt8B6JgQwFtmBzWsgHsmAN0QtKw9GADakRNGiDokADSZw2HMkRIy%2BZdLkcyZFMkMBdVZq2QAZsq4d8RyMk4BrRAH0yHHUhrW2xILkEAE0p7SgVUDGMAI2R8aBNXSxCAX0yILJAsoA&tsconfig=N4KABGBEDGD2C2AHAlgGwKYCcDyiAuysAdgM6QBcYoEEkJemy0eAcgK6qoDCAFutAGsylBm3TgwAXxCSgA&tokens=false

Repro Code

abstract class Ignored { abstract get StrictPascalCase(): string; }

ESLint Config

module.exports = {
  parser: "@typescript-eslint/parser",
  rules: {
    "@typescript-eslint/naming-convention": ["error", {
      "selector": ["accessor"],
      "format": ["snake_case"],
      "modifiers": ["abstract"]
    }]
  },
};

tsconfig

{
  "compilerOptions": {
    "strictNullChecks": true
  }
}

Expected Result

I expected it to report accessor StrictPascalCase not matching the config.

Actual Result

Nothing.

Additional Info

No response

@arka1002 arka1002 added bug Something isn't working package: eslint-plugin Issues related to @typescript-eslint/eslint-plugin triage Waiting for maintainers to take a look labels Jan 12, 2024
@arka1002 arka1002 changed the title Bug: [naming-convention] Abstract accessors aren't supported Bug: [naming-convention] support the abstract accessor Jan 12, 2024
arka1002 added a commit to arka1002/typescript-eslint that referenced this issue Jan 12, 2024
@bradzacher bradzacher changed the title Bug: [naming-convention] support the abstract accessor [naming-convention] support the abstract accessor Jan 12, 2024
@bradzacher bradzacher added enhancement: plugin rule option New rule option for an existing eslint-plugin rule accepting prs Go ahead, send a pull request that resolves this issue and removed bug Something isn't working triage Waiting for maintainers to take a look labels Jan 12, 2024
arka1002 added a commit to arka1002/typescript-eslint that referenced this issue Jan 13, 2024
@arka1002
Copy link
Contributor Author

fixed in #8084

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
accepting prs Go ahead, send a pull request that resolves this issue enhancement: plugin rule option New rule option for an existing eslint-plugin rule package: eslint-plugin Issues related to @typescript-eslint/eslint-plugin
Projects
None yet
Development

No branches or pull requests

2 participants