On 17 November, Oxc announced tsrs support in Oxlint. The Rust-based TypeScript engine is an alternative to tsgolint behind the same Oxlint CLI and configuration. If your team already runs typed linting, this is an engine change. If your checks consist of a syntax-only linter and tsc --noEmit, it is an opportunity to add a kind of check you may not be running at all.
Those are two different decisions. One is about preserving your checks and making them cheaper. The other is about finding bugs your existing checks can reasonably accept.
The save button that gets ahead of itself
Consider a settings form. The API helper returns a promise that resolves only when the server confirms the write. The UI calls the helper and immediately says “Saved”.
declare function saveSettings(): Promise<void>;
declare function setSaveState(
state: "saving" | "saved" | "failed"
): void;
function onSave(): void {
setSaveState("saving");
saveSettings();
setSaveState("saved");
}
Nothing in the types says a caller must use the return value of saveSettings. The call has valid arguments, and every state is a valid string. Both snippets in this article passed TypeScript 6.0.3 with --noEmit --strict --lib ES2022 in isolated files. The problem is the order in which the UI performs its side effects.
On a slow request, “Saved” can appear while the server is still working. On rejection, the UI can keep saying “Saved” even though nothing was committed. A developer testing against a fast local service might never notice. Reloading after an intentionally rejected request is a much better test than looking for a green toast.
Oxlint’s typescript/no-floating-promises rule can flag the bare call because it knows the expression returns a promise. It can use that type information even when the helper comes from another module and its declaration is nowhere near the event handler. A syntax-only check sees a function call; guessing from the spelling of its name would miss a wrapper called persist and falsely accuse a synchronous helper called saveSettings.
In separate clean fixtures, Oxlint 1.95.0 reported the floating promise with both tsrs 7.1.0-beta.tsrs5 and oxlint-tsgolint 7.0.2009. The awaited version passed the rule in both. Those are diagnostic checks on two small files, not a performance comparison.
The fix is to tie the success state to the completion the user cares about:
async function onSave(): Promise<void> {
setSaveState("saving");
try {
await saveSettings();
setSaveState("saved");
} catch {
setSaveState("failed");
}
}
The example assumes the UI receives a meaningful rejection when the server does not confirm the write. A helper that swallows an error or resolves on a response that merely queues the work would still make this UI lie. The lint rule sees the promise is handled. It cannot tell you what resolving it really means. Test that with a deferred response and a rejected response: verify that “Saving” stays visible until success, and that failure never flashes “Saved”.
An explicit void is another trap. By default, the rule allows void somePromise() to express that the caller is deliberately ignoring the promise. As typescript-eslint’s rule documentation explains, void does not handle rejection or change runtime behaviour. Where a framework needs a synchronous callback and the work is genuinely independent, give the asynchronous operation its own error handler. Where the result determines the next screen, wait for it.
What actually changes with tsrs?
For typed linting, Oxlint needs answers about the types that appear in the project. The backend can resolve the type of the call in the example; the lint rule uses that answer to decide whether the code warrants a diagnostic. The reusable part is the analysis, not a claim that a typechecker and linter have the same job.
Oxc’s type-aware linting guide distinguishes enabling type-aware rules with --type-aware from asking for compiler diagnostics with --type-check. With tsrs installed, current Oxlint can select it automatically. That makes evaluation easy to try, but it is also a reason to pin both packages and confirm which backend your CI actually used. A benchmark comparing two jobs that silently chose the same backend tells you very little.
In its announcement, Oxc reports up to 5× faster typed linting than the tested tsgolint version and up to 7× faster for its combined lint and typecheck benchmark configurations. Those are upstream maxima, not an estimate for a given workspace. When both kinds of checks run together, the engine can reuse analysis rather than starting over. Whether you see a useful difference depends on what the runner already caches, how your project is split and how much of the job was spent checking TypeScript in the first place.
Get the same warnings before chasing faster times
If you already use Oxlint with tsgolint, compare it with tsrs at the same Oxlint version and on the same commit. Keep the rule set, tsconfig files, working directory and runner fixed. Have each job record its package versions, backend and file scope. Compare diagnostics by file, rule and location rather than counting lines. Record the lockfile with the result: a later clean install that changed a backend version is a different experiment. The same principle applies to the rest of the CI toolchain. A clean baseline is useful, but add a deliberate failing fixture like the save above so you can prove both backends still catch the behaviour you care about.
For an ESLint and typescript-eslint project, the comparison is wider. Inventory framework rules, project-aware settings, custom plugins and autofixes before removing anything. It can make sense to adopt a narrower fast check first and keep ESLint for the rules it is already answering. Conversely, if you run syntax lint and plain TypeScript today, report the new diagnostics separately from runtime. You are paying for additional coverage; that is not an apples-to-apples speed test.
Keep your existing TypeScript build or tsc command in place during the trial. Before considering consolidation, compare the actual compiler diagnostics on your supported projects, including project references or generated types if you depend on them. A green lint job does not demonstrate that your build still emits the files your consumers need.
Try it on one package first
Start with a package that has real async boundaries and a CI job slow enough to measure. Run both configurations on the same machine several times, with cold and warm runs recorded separately. Compare median and slower runs, peak memory where your runner exposes it, and the end-to-end time developers actually wait. Separate install time from lint time and keep formatter, tests and builds unchanged. If checks already run in parallel, halving lint time might not shorten the critical path at all.
Before rolling out to the whole repository, run the candidate job in parallel without making it required. Investigate differences before choosing which job to keep; fixing or suppressing a warning in only one arm makes the comparison harder to interpret.
Then make two deliberate failures: leave a promise bare, and introduce a plain compiler type error. Confirm the jobs that are meant to catch each failure still do so. For the save itself, simulate a rejection in a UI test. Those three checks answer three different questions about lint policy, compiler coverage and product behaviour.
Use tsrs if the diagnostics you depend on stay intact and the shorter feedback loop is worth another backend in your toolchain. If you are adding typed lint for the first time, lead with one rule that would have caught a bug worth fixing. “Saved” appearing before a write succeeds is a good place to start.
