tools
tools copied to clipboard
🐛 `lint/suspicious/noRedeclare` - Index signatures in same object marked as invalid
Environment information
CLI:
Version: 12.1.0
Color support: true
Platform:
CPU Architecture: aarch64
OS: macos
Environment:
ROME_LOG_DIR: unset
NO_COLOR: unset
TERM: "xterm-256color"
JS_RUNTIME_VERSION: "v18.14.0"
JS_RUNTIME_NAME: "node"
NODE_PACKAGE_MANAGER: "yarn/3.3.1"
Rome Configuration:
Status: Loaded successfully
Formatter disabled: false
Linter disabled: false
Organize imports disabled: true
VCS disabled: true
Workspace:
Open Documents: 0
Discovering running Rome servers...
Running Rome Server: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
i The client isn't connected to any server but rage discovered this running Rome server.
Server:
Version: 12.1.0
Name: rome_lsp
CPU Architecture: aarch64
OS: macos
Workspace:
Open Documents: 0
Other Active Server Workspaces:
Workspace:
Open Documents: 2
Client Name: Visual Studio Code
Client Version: 1.78.2
Rome Server Log:
! Please review the content of the log file before sharing it publicly as it may contain sensitive information:
* Path names that may reveal your name, a project name, or the name of your employer.
* Source code
What happened?
Specifying multiple index signatures with the same name in separate type fields causes noRedeclare
to mark all except first as invalid.
export type TypeWithObjects = {
valid: {
[index: string]: string;
}
invalid: {
[index: string]: string;
}
}
Expected result
index
on line 7 should not be marked as invalid
Code of Conduct
- [X] I agree to follow Rome's Code of Conduct