Thank you for your interest in contributing to Ranu.js!
Ranu.js is an open-source project, and contributions from the community are warmly welcomed. Whether you are fixing typos, improving documentation, submitting bug fixes, or proposing new framework features, this guide will help you get started smoothly.
Note
Public Alpha Stage
Ranu.js is currently in Public Alpha development. Architecture, APIs, package boundaries, and internal workflows are actively evolving as the project progresses toward the stable V1 milestone.
Important
External Contribution Policy (Prior Approval Required)
To protect framework stability, API consistency, and security during our Public Alpha development, direct Pull Requests from external contributors are not accepted without prior permission.
Before writing code or opening a PR, please submit a Contribution & Permission Request issue. Once maintainers approve your proposal (or apply the contribution: approved label), you are warmly welcomed to submit your PR. Direct unapproved PRs will be held by our automated gatekeeper bot until permission is granted.
To save your time and keep contributions streamlined, refer to this quick guide:
| Type of Contribution | Permission Request First? | Changeset Required? | Example Commit Prefix |
|---|---|---|---|
| New Feature / API Change | ✅ Yes (Open Issue first) | ✅ Yes | feat(runtime): add response streaming support |
| Bug Fix (Kernel / Adapters / AI) | ✅ Yes (Open Issue first) | ✅ Yes (if in published package) | fix(router): resolve dynamic segment matching |
| Documentation / Typo Fixes | ✅ Yes (Open Issue first) | ❌ No | docs: fix routing example typo |
| Tests & Internal Tooling | ✅ Yes (Open Issue first) | ❌ No | test: add unit tests for cookie parsing |
| Refactoring (Architecture) | ✅ Yes (Open Issue first) | ❌ No | refactor(build): simplify module graph traversal |
Ranu.js is developed as a pnpm monorepo.
- Node.js >= 22.0.0
- pnpm >= 11.0.0
To enable or install pnpm:
# Option 1: Using Corepack (recommended)
corepack enable
# Option 2: Using npm globally
npm install -g pnpm# 1. Clone the repository
git clone https://github.com/hoslift/ranu.js.git
cd ranu.js
# 2. Install dependencies across all packages
pnpm install
# 3. Build all workspace packages
pnpm buildThe monorepo is organized cleanly into modular packages and directories:
| Directory | Purpose |
|---|---|
packages/ |
Core framework packages (router, react, runtime, build, server, etc.) |
adapters/ |
Deployment adapters (e.g., @ranujs/adapter-vercel) |
create-ranu/ |
The official CLI scaffolder (create-ranujs) |
examples/ |
Standalone, canonical reference applications using public APIs |
fixtures/ |
Internal test applications used by test harnesses |
tests/ |
End-to-end, API contract, security, and performance test suites |
docs/ |
Specifications and public documentation |
rfcs/ |
Architectural proposals and Request for Comments |
tooling/ |
Internal repository configs and build tools |
Always create a dedicated feature or fix branch from main:
git checkout -b <type>/<short-description>Branch naming conventions:
feat/<feature-name>(e.g.,feat/edge-adapter)fix/<bug-name>(e.g.,fix/cookie-parsing)docs/<topic>(e.g.,docs/quickstart-guide)test/<component>(e.g.,test/ssr-streaming)chore/<task>(e.g.,chore/bump-deps)
Ranu.js follows the Conventional Commits standard. Please use structured commit messages:
<type>(<scope>): <short description>
feat: A new feature or capabilityfix: A bug fixdocs: Documentation changes onlytest: Adding or correcting testsrefactor: Code change that neither fixes a bug nor adds a featureperf: Performance improvementchore: Maintenance tasks, dependency updates, tooling
feat(react): support custom error boundaries in nested layoutsfix(router): sanitize regex in dynamic path generationdocs: update npm-first quick start instructionstest(security): add test suite for server-only boundaries
Any code change that alters framework runtime behavior or fixes a bug must include tests.
# Run all tests
pnpm test
# Run unit tests only
pnpm test:unit
# Run API contract tests
pnpm test:api
# Run integration tests
pnpm test:integrationBefore opening a pull request, run the local validation pipeline to ensure all checks pass:
# Complete local validation (same as CI pipeline)
pnpm preprAlternatively, you can run individual checks:
pnpm typecheck # TypeScript type checking
pnpm lint # ESLint code analysis
pnpm format:check # Prettier formatting check
pnpm ci:verify # Verification suite without cleaningIf your pull request introduces changes to packages that are published to npm (e.g., @ranujs/core, create-ranujs, or adapters), you must include a Changeset:
pnpm changesetFollow the interactive prompts:
- Select the packages affected by your change (use arrow keys and space).
- Choose the version impact:
- patch: Bug fixes and minor internal updates.
- minor: New backward-compatible features.
- major: Breaking changes (discuss with maintainers first).
- Write a clear, concise summary of the change. This summary will be automatically added to
CHANGELOG.mdupon release.
Changes affecting only
docs/,tests/,examples/, or internal tooling do not require a Changeset.
Ranu.js employs a structured hybrid release architecture:
- Core Framework (
@ranujs/core&create-ranujs): Kept in synchronized lockstep. When core framework releases an update, the CLI scaffolder updates alongside it so newly created projects always target the latest core engine. - Adapters Ecosystem (
adapters/*): Independently versioned deployment plugins.- Public Alpha (
v0.1.x): Existing and newly authored adapters start atv0.1.0(or the active alpha line) to facilitate early iteration. v1.0.0Milestone: Upon official General Availability, the entire ecosystem (Core, CLI, and all active adapters) aligns tov1.0.0. Alpha (v0.1.x) is officially retired.- Post-
v1.0.0Era: Any newly authored adapter begins directly atv1.0.0withpeerDependencies: { "@ranujs/core": ">=1.0.0" }. Adapters may receive independent patch or minor updates without triggering an artificial core release.
- Public Alpha (
- Push your branch to your fork or repository:
git push origin <branch-name>
- Open a Pull Request targeting the
mainbranch. - Complete the PR template with:
- A clear explanation of what changed and why.
- Links to relevant approved issue (e.g.,
Closes #123). - How the change was tested.
Before submitting your pull request, verify:
- A Contribution Request issue was approved prior to submitting this PR.
- Changes are focused and do not include unrelated code or formatting changes.
- Code follows project conventions and passes
pnpm lint. - TypeScript compiles cleanly with
pnpm typecheck. - Relevant unit or integration tests are added/updated and pass (
pnpm test). - Changeset is added via
pnpm changeset(if published packages were modified). - Local pre-PR validation passes (
pnpm prepr).
During Public Alpha development, architecture and internal APIs evolve rapidly. Requiring an approved Contribution Request ensures maintainer alignment, prevents duplicated work, and keeps the code base secure and consistent.
Check our GitHub Issues and filter by labels:
good first issue— Perfect for new contributors.help wanted— Community contributions welcome.documentation— Improvements to guides, docstrings, and examples.
Don't worry! Click Details on the failing GitHub Actions job to view the error log. You can reproduce the exact check locally by running:
pnpm preprFix the reported error, commit, and push to your PR branch.
No. Changesets are only required when modifying code inside published packages (packages/ or adapters/).
All contributors are expected to uphold our standards of a welcoming, inclusive, and harassment-free community. Please review CODE_OF_CONDUCT.md before participating.
Please do not report security vulnerabilities through public GitHub Issues. Review our SECURITY.md policy for responsible private disclosure.
By contributing to Ranu.js, you agree that your contributions will be licensed under the MIT License.
Ranu.js — Rethinking the Full-Stack Web.
Maintained by Hoslift.