Skip to content
This repository has been archived by the owner on Aug 31, 2023. It is now read-only.

🐛 lint/correctness/noUndeclaredVariables incorrectly identifies AggregateError as an undeclared variable. #4365

Closed
1 task done
jack-weilage opened this issue Apr 10, 2023 · 0 comments · Fixed by #4366
Assignees
Labels
A-Diagnostic Area: errors and diagnostics S-Bug: confirmed Status: report has been confirmed as a valid bug

Comments

@jack-weilage
Copy link

Environment information

CLI:
  Version:                      12.0.0
  Color support:                true

Platform:
  CPU Architecture:             x86_64
  OS:                           linux

Environment:
  ROME_LOG_DIR:                 unset
  NO_COLOR:                     unset
  TERM:                         "xterm-256color"
  JS_RUNTIME_VERSION:           "v19.4.0"
  JS_RUNTIME_NAME:              "node"
  NODE_PACKAGE_MANAGER:         "npm/9.3.1"

Rome Configuration:
  Status:                       Loaded successfully
  Formatter disabled:           false
  Linter disabled:              false
  Organize imports disabled:    true

Workspace:
  Open Documents:               0

What happened?

Reproduction:

new AggregateError()
//  ^ The AggregateError variable is undeclared.

Playground link: https://docs.rome.tools/playground/?lintRules=all&code=bgBlAHcAIABBAGcAZwByAGUAZwBhAHQAZQBFAHIAcgBvAHIAKAApAA%3D%3D

Expected result

Rome should consider AggregateError a JavaScript built-in and not warn about it being undeclared.

Code of Conduct

  • I agree to follow Rome's Code of Conduct
@jack-weilage jack-weilage added the S-To triage Status: user report of a possible bug that needs to be triaged label Apr 10, 2023
@denbezrukov denbezrukov self-assigned this Apr 11, 2023
@denbezrukov denbezrukov added S-Bug: confirmed Status: report has been confirmed as a valid bug A-Diagnostic Area: errors and diagnostics and removed S-To triage Status: user report of a possible bug that needs to be triaged labels Apr 11, 2023
@denbezrukov denbezrukov changed the title 🐛 lint/correctness/noUnusedVariables incorrectly identifies AggregateError as an undeclared variable. 🐛 lint/correctness/noUndeclaredVariables incorrectly identifies AggregateError as an undeclared variable. Apr 11, 2023
denbezrukov added a commit to denbezrukov/tools that referenced this issue Apr 11, 2023
…tly identifies AggregateError as an undeclared variable. rome#4365
denbezrukov added a commit to denbezrukov/tools that referenced this issue Apr 11, 2023
…tly identifies AggregateError as an undeclared variable. rome#4365
ematipico pushed a commit that referenced this issue Apr 11, 2023
…tly identifies AggregateError as an undeclared variable. #4365 (#4366)

* fix(rome_js_analyze): lint/correctness/noUndeclaredVariables incorrectly identifies AggregateError as an undeclared variable. #4365

* fix(rome_js_analyze): lint/correctness/noUndeclaredVariables incorrectly identifies AggregateError as an undeclared variable. #4365
jack-weilage added a commit to jack-weilage/vite-image that referenced this issue Apr 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Diagnostic Area: errors and diagnostics S-Bug: confirmed Status: report has been confirmed as a valid bug
Projects
None yet
2 participants