Respect project package manager and installation in workflows

Author: Arcadi4Created Oct 1, 2026Updated Oct 1, 2026

Currently, react-doctor promotes an npx-based UX by default. This is undesirable in many cases:

  • When another package manager is enforced, the action workflow and the default npm script "doctor": "npx react-doctor@latest" might fail in CI environments.

    For example, the following setup, common in pnpm projects, will break the CI:

    "devEngines": {
      "packageManager": {
        "name": "pnpm",
        "version": "x.y.z",
        "onFail": "download"
      }
    }
  • Difficult for users to pin to a specific version.

  • Adding to devDependencies is mostly unavoidable anyhow if customization is needed. doctor.config.ts imports from the package.

Proposed fix:

  • Make the workflow adapt to different project setups (pnpm, yarn, bun, etc.).
  • Always execute via the package manager instead of npx if react-doctor is listed as a dependency.