This guide helps contributors set up the project locally, understand the monorepo structure, and run builds, tests, and examples.
Before starting, make sure you have the following installed:
- Bun
- Git
You can verify Bun installation with:
bun --versiongit clone https://github.com/Karanjot786/TermUI.git
cd TermUIInstall all workspace dependencies from the repository root:
bun installThis project uses a monorepo layout.
.
├── packages/
├── examples/
├── package.json
├── bun.lockb
├── README.md
├── CONTRIBUTING.md
└── DEVELOPMENT.md
The packages/ directory contains the core libraries and modules used across the project.
Example structure:
packages/
├── motion/
├── router/
├── core/
└── ...
Each package contains its own source code, tests, and configuration.
The examples/ directory contains runnable demo applications that showcase how the packages work together.
Example:
examples/dashboard
Run all commands from the repository root unless stated otherwise.
Build all packages:
bun run buildRun the full test suite:
bun run testRun TypeScript type checking:
bun run typecheckTo run tests for a specific package, navigate into that package directory.
Example:
cd packages/router
bun testYou can replace router with any package name inside the packages/ folder.
To start the dashboard example:
cd examples/dashboard
bun run devThis starts the development server for the example application.
Typical workflow for contributors:
- Fork the repository
- Clone your fork
- Create a new branch
- Make changes
- Run build, tests, and typecheck
- Open a Pull Request
Example:
git checkout -b feat/update-docs| Command | Purpose |
|---|---|
bun install |
Install dependencies |
bun run build |
Build all packages |
bun run test |
Run all tests |
bun run typecheck |
Run type checks |
bun test |
Run tests for current package |
bun run dev |
Start example app |
- Read
CONTRIBUTING.mdbefore opening a Pull Request. - Keep changes focused and minimal.
- Ensure tests pass before submitting changes.
Happy contributing!