Wiki
the map of any codebase

Dependencies

Dependencies

ky ships with zero runtime dependencies. The package.json manifest declares no dependencies field — only devDependencies used for building, linting, type-checking, and testing. The published package contains only the distribution directory.

Runtime footprint

The library is distributed as ESM only:

  • "type": "module"
  • "exports" points to ./distribution/index.js with types at ./distribution/index.d.ts
  • "sideEffects": false (tree-shakable)
  • "engines": { "node": ">=22" }

Because there are no runtime dependencies, ky relies entirely on the host platform's Fetch API and Web standards (e.g. AbortSignal, referenced in source/utils/merge.ts via supportsAbortSignal).

Development dependencies

The dev-only toolchain falls into four groups.

Build & TypeScript

  • typescript (^5.9.3) — compiles source/ to distribution/ via tsc --project tsconfig.dist.json (see the build script).
  • @sindresorhus/tsconfig (^8.1.0) — base tsconfig preset.
  • del-cli (^7.0.0) — clears distribution before each build.
  • tsx (^4.21.0) — used as a Node loader (--import=tsx/esm) so ava can execute TypeScript test files directly.

Linting

  • xo (^1.2.3) — runs as the first step of npm test. The manifest's xo block disables a number of rules (e.g. unicorn/filename-case, several @typescript-eslint/no-unsafe-* rules, unicorn/no-invalid-fetch-options).

Testing

  • ava (^6.4.1) — test runner; configured to treat .ts files as ESM modules.
  • playwright (^1.58.2) — browser-based testing (a debug script runs ava under PWDEBUG=1).
  • expect-type (^1.3.0) and @type-challenges/utils (^0.1.1) — compile-time type assertions. The latter is imported in source/core/constants.ts as import type {Expect, Equal} from '@type-challenges/utils', used for type-level checks inside the source tree.
  • jest-leak-detector (^30.2.0) — memory-leak detection in tests.

Test fixtures (HTTP servers and bodies)

  • express (^5.2.1) with @types/express (^5.0.6) — used by test/helpers/create-http-test-server.ts to build the test HTTP server (import express from 'express').
  • busboy (^1.6.0) with @types/busboy (^1.5.4) — multipart parsing in tests.
  • @types/node (^25.3.0) — Node typings, used throughout (e.g. import http from 'node:http' in the test helper).

Notable absences

The keywords field lists comparable libraries (got, axios, node-fetch) for discoverability, but none of them are dependencies — ky is built directly on the platform Fetch API.

npm · 15

@sindresorhus/tsconfig^8.1.0dev
@type-challenges/utils^0.1.1dev
@types/busboy^1.5.4dev
@types/express^5.0.6dev
@types/node^25.3.0dev
ava^6.4.1dev
busboy^1.6.0dev
del-cli^7.0.0dev
expect-type^1.3.0dev
express^5.2.1dev
jest-leak-detector^30.2.0dev
playwright^1.58.2dev
tsx^4.21.0dev
typescript^5.9.3dev
xo^1.2.3dev

Cited sources· 7