What version of Oxlint are you using?
1.70.0
What command did you run?
oxlint@latest --fix --fix-suggestions --fix-dangerously
What does your .oxlintrc.json (or oxlint.config.ts) config file look like?
The whole reason I'm using oxlint is so that I don't need yet another config file polluting small codebases
What happened?
Oxlint incorrectly flags a ternary as being "unused" when it more than obviously executes either one of two possible expressions.
export function tty(query, question = false, raw = false) {
return new Promise((resolve) => {
stdin.once(`data`, (data) => {
resolve(util.inspect(data.toString()));
});
raw ? write(query) : ansi(query, question);
});
}
It flags the truthy ? expression : expression part as unused, which makes no sense whatsoever
⚠ eslint(no-unused-expressions): Expected expression to be used
╭─[tty.js:56:5]
55 │ });
56 │ raw ? write(query) : ansi(query, question);
· ───────────────────────────────────────────
57 │ });
╰────
help: Consider using this expression or removing it
What version of Oxlint are you using?
1.70.0
What command did you run?
oxlint@latest --fix --fix-suggestions --fix-dangerously
What does your
.oxlintrc.json(oroxlint.config.ts) config file look like?The whole reason I'm using oxlint is so that I don't need yet another config file polluting small codebases
What happened?
Oxlint incorrectly flags a ternary as being "unused" when it more than obviously executes either one of two possible expressions.
It flags the
truthy ? expression : expressionpart as unused, which makes no sense whatsoever