Skip to content

linter: oxlint-no-deprecated-indirect #26545

Open
oxc-project/tsgolint
#1209

Description

@pirty6

What version of Oxlint are you using?

1.80.0

What command did you run?

oxlint --type-aware

What does your .oxlintrc.json (or oxlint.config.ts) config file look like?

{
  "$schema": "https://raw.githubusercontent.com/oxc-project/oxc/main/npm/oxlint/configuration_schema.json",
  "rules": {
    "typescript/no-deprecated": "error"
  }
}

What happened?

When a class implements an interface whose method carries /** @deprecated */, and the class stores a property whose declared type is jest.MockedFunction<Interface['method']>, accessing that property (e.g. instance.method.mockReturnValue(...)) is correctly flagged by Eslint, while oxlint fails to flag it.

Case Shape Oxlint (typescript/no-deprecated) ESLint (@typescript-eslint/no-deprecated)
A Property with @deprecated JSDoc directly on the declaration ✅ Flags ✅ Flags
B Property typed Interface['method'] (indexed access) ✅ Flags ✅ Flags
C Interface property typed jest.MockedFunction<Interface['method']> (utility‑type‑wrapped indexed access, no implements) ❌ ❌
D Class property typed jest.MockedFunction<Interface['method']>, class implements the deprecated‑bearing interface ❌ ✅ Flags

Oxlint's rule does not propagate deprecation across the implements relationship when the property is wrapped in a utility type.

Here's a repo with a mininimal repo of the issue: https://github.com/pirty6/oxlint-no-deprecated-indirect-repro

Activity

  1. added theissue type on Sep 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Fields

    Priority

    None yet

    Effort

    None yet

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions