Skip to content

Latest commit

 

History

5,197 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Counterfact

Build the frontend. Don’t wait for the backend.

Counterfact turns an OpenAPI document into a useful local API in one command. The published package and canonical user documentation live in packages/counterfact.

This repository is a Yarn workspace monorepo. Its root package is private and coordinates builds, tests, releases, examples, and the documentation site.

Focused workspace packages:

  • @counterfact/client — reusable, OpenAPI-aware HTTP requests without the simulator or REPL.
  • @counterfact/generator — route scaffolds, generated TypeScript contracts, scenarios, and compatible shared templates.
  • @counterfact/openapi — standalone OpenAPI loading, bundling, dereferencing, and overlays.
  • @counterfact/repl — an embeddable Node.js REPL over focused client and runtime contracts.
  • @counterfact/runtime — route dispatch, registries, validation, hot reload, proxying, and Koa/MSW adapters.
  • @counterfact/types — shared TypeScript contracts used by Counterfact internals and generated handlers.

About

Turn an OpenAPI spec into a local API in one command. Build and test your frontend with custom responses, shared state, and simulated failures, without waiting for the backend.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

170 stars

Watchers

4 watching

Forks

Releases

Sponsor this project

Packages

Used by

Contributors

Languages