fork-ts-checker-webpack-plugin

Runs TypeScript type checking in a separate forked process so webpack builds stay fast.

Tool
npm
v9.1.0
2,000stars
MIT License

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
56/100Fair
Development Activity4
Maintenance44
Community76
Maturity60
Momentum40

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
74/100Good
Architecture80
Code Quality78
Innovation68
Learning Curve70

fork-ts-checker-webpack-plugin offloads TypeScript type checking to a forked child process, decoupling slow full-program type analysis from webpack’s own compilation pipeline. Instead of blocking every rebuild on tsc-level checks, the plugin hands type checking to a background worker communicating over a lightweight RPC layer built on Node’s IPC channel, and reports diagnostics back to webpack asynchronously once they’re ready.

It is designed to sit alongside a transpile-only loader (typically ts-loader with transpileOnly: true or babel-loader), so webpack emits JavaScript immediately while the checker validates types on its own schedule. This split is what lets teams keep using strict TypeScript project references, incremental builds, and .tsbuildinfo caching without paying their cost on every save during development.

What You Get

  • A ForkTsCheckerWebpackPlugin class that taps into webpack’s compiler hooks (afterEnvironment, run/watchRun, done) to start, feed, and stop a background type-checking worker
  • Support for TypeScript project references and incremental/--build mode, including write-dts, write-tsbuildinfo, and write-references output modes
  • Configurable issue filtering (include/exclude) that matches on severity, error code, or file glob before issues ever reach webpack’s error/warning output
  • Pluggable diagnostic formatters (basic, codeframe, or a custom function) for how type errors are rendered in the terminal
  • async mode that reports issues after compilation finishes instead of blocking the watch/rebuild cycle, plus webpack-dev-server integration for overlay/logging
  • Cosmiconfig-based configuration, so options can live in package.json, .fork-ts-checkerrc, or fork-ts-checker.config.js instead of only the plugin constructor

Common Use Cases

  • Pairing with ts-loader in transpileOnly mode so webpack emits JS immediately while this plugin catches type errors in parallel
  • Keeping large monorepos with TypeScript project references fast to rebuild by running --build-equivalent checking off the main thread
  • Surfacing type errors in the webpack-dev-server overlay during local development without adding type-check latency to hot reloads
  • Enforcing selective type-error policies in CI/dev by including or excluding specific files, error codes, or severities from failing a build

Under The Hood

Architecture The plugin’s apply(compiler) method in src/plugin.ts wires a small set of single-purpose hook modules (src/hooks/tap-after-environment-to-patch-watching.ts, tap-start-to-run-workers.ts, tap-after-compile-to-add-dependencies.ts, tap-stop-to-terminate-workers.ts, tap-error-to-log-message.ts) into webpack’s compiler lifecycle, keeping each concern (patching watch mode, spawning workers, reporting dependencies, cleanup, error logging) in its own file rather than one monolithic apply. Type checking itself never runs in-process: src/rpc/rpc-worker.ts forks a child process per worker (get-issues-worker.ts, get-dependencies-worker.ts under src/typescript/worker), passing config through an env var and a custom wrapRpc/exposeRpc protocol built on Node’s IPC channel with advanced serialization, so a plugin instance can restart or terminate a checker process independently of webpack’s own compilation.

Tech Stack Written in TypeScript targeting webpack 5 and TypeScript >3.6 as peer dependencies, with cosmiconfig for layered configuration discovery (constructor options merged via deepmerge over package.json/.fork-ts-checkerrc/fork-ts-checker.config.js), schema-utils validating options against a JSON Schema (plugin-options.json), chokidar for filesystem watching, minimatch for glob-based issue include/exclude filters, and semver for version comparisons; the package is built with tsc directly (no bundler), tested with jest/ts-jest, and released via semantic-release from a Yarn Berry (v4) workspace.

Code Quality The repo runs both a unit suite (test/unit, covering RPC wrapping, issue matching, formatters, path utilities) and a full end-to-end suite (test/e2e, driving real webpack builds against fixture projects via npm pack), with eslint (typescript-eslint + prettier) enforced through husky/lint-staged pre-commit hooks and commitlint gating conventional-commit messages. Public types (RpcMethod, IssueFilter, ForkTsCheckerWebpackPluginOptions) are explicit and exported, and CI runs the full build+test+lint pipeline on every push.

API Design The public surface is a single default-exported class matching webpack’s own plugin convention (new ForkTsCheckerWebpackPlugin(options) + .apply(compiler)), so integration requires no new mental model beyond “add it to the plugins array.” Configuration is grouped into a small number of nested option objects (typescript, issue, formatter, logger, devServer) with sensible defaults, and the cosmiconfig support means teams can keep plugin config out of webpack.config.js entirely if they prefer a dedicated config file.

Used by 9 apps in this directory

TypeScript
72%
AGPL 3.0

APITable

Low Code Platforms · Databases

15,588

API-first collaborative spreadsheet-database platform that auto-generates REST APIs and lets teams build internal tools, CRMs, and dashboards without code.

View details
74
Repo Health
77
Technical
60
Dependency
Built with
TypeScript72%
Java22%
Updated yesterday
TypeScript
97%
AGPL 3.0

Bigcapital

Invoicing Finance

3,884

Self-hostable double-entry accounting platform with invoicing, inventory, multi-currency, and real-time financial reporting for small and medium businesses.

View details
91
Repo Health
77
Technical
61
Dependency
Built with
TypeScript97%
Updated yesterday
Go
65%
AGPL 3.0

Fider

Product Management · Customer Support

4,499

Open-source feedback portal where customers submit, vote on, and track feature requests so product teams build what actually matters.

View details
88
Repo Health
85
Technical
71
Dependency
Built with
Go65%
TypeScript29%
Updated 5 days ago
TypeScript
92%
MIT

GB Studio

Developer Tools · Game Development · Design Tools

9,395

Drag-and-drop retro Game Boy game creator that compiles real ROMs — no coding required.

View details
89
Repo Health
83
Technical
79
Dependency
Built with
TypeScript92%
Updated yesterday
TypeScript
49%
AGPL 3.0

Grafana

Monitoring · Analytics

76,643

The open-source observability platform that unifies metrics, logs, and traces from any data source into dynamic, queryable dashboards.

View details
95
Repo Health
91
Technical
63
Dependency
Built with
TypeScript49%
Go45%
Updated today
Go
62%
Apache 2.0

Harness Open Source

Developer Tools · Devops · Code Editors

38,251

A unified open source DevOps platform combining Git hosting, CI/CD pipelines, cloud development environments, and artifact registries in a single self-hosted system.

View details
89
Repo Health
79
Technical
64
Dependency
Built with
Go62%
TypeScript34%
Updated 3 days ago
TypeScript
71%
Other

highlight.io

Developer Tools · Analytics · Monitoring

9,372

Open-source full-stack monitoring that unifies session replay, error tracking, logging, and distributed tracing so you can stop context-switching between tools.

View details
69
Repo Health
78
Technical
65
Dependency
Built with
TypeScript71%
Go16%
Updated 2 weeks ago
TypeScript
61%
EPL-2.0

Huly Platform

Project Management · Team Chat · Collaboration

27,586

Open-source all-in-one workspace that replaces Linear, Jira, Slack, and Notion for product and engineering teams.

View details
89
Repo Health
86
Technical
62
Dependency
Built with
TypeScript61%
Svelte34%
Updated 1 weeks ago
TypeScript
88%
Other

strapi

CMS

73,083

Open-source headless CMS that auto-generates REST and GraphQL APIs from your content models, with a fully customizable admin panel you control.

View details
93
Repo Health
84
Technical
66
Dependency
Built with
TypeScript88%
JavaScript12%
Updated yesterday

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers

Search