https://github.com/feunard/alepha
🍃 The AI-Native Application Engine
https://github.com/feunard/alepha
ai bun framework nodejs react rest-api ssr typescript
Last synced: about 1 month ago
JSON representation
🍃 The AI-Native Application Engine
- Host: GitHub
- URL: https://github.com/feunard/alepha
- Owner: feunard
- License: mit
- Created: 2024-12-29T16:02:47.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2026-02-08T00:28:29.000Z (about 2 months ago)
- Last Synced: 2026-02-08T09:29:44.090Z (about 2 months ago)
- Topics: ai, bun, framework, nodejs, react, rest-api, ssr, typescript
- Language: TypeScript
- Homepage: https://alepha.dev
- Size: 14.1 MB
- Stars: 10
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE
- Code of conduct: .github/CODE_OF_CONDUCT.md
- Security: .github/SECURITY.md
- Support: .github/SUPPORT.md
Awesome Lists containing this project
README
> [!WARNING]
> This project is in active development and may not be suitable for production use. Please report any issues or bugs on [GitHub](https://github.com/feunard/alepha/issues).
## What is Alepha?
Full-stack TypeScript framework for agentic era. Define your schema once — get database, API, types, and forms.
- **One schema, everywhere** — Database, API validation, TypeScript types, React forms — all from one definition
- **Full autocomplete** — Client calls server with complete type safety, zero codegen
- **Multi-runtime** — Same code runs on Node, Bun, and Cloudflare Workers
- **Deploy anywhere** — Cloudflare, Vercel, Docker, bare metal
Built on predictable conventions and typed primitives — works great with AI coding assistants (BYOA).
Each layer builds on the previous.
| Layer | Description | Primitives |
|-------|-------------|---------------------------------------------------------|
| **Foundation** | DI, lifecycle, config | `$inject`, `$env`, `$module`, `$hook`, `$logger` |
| **Backend** | Database, queues, storage, API | `$entity`, `$action`, `$queue`, `$bucket`, `$scheduler` |
| **Frontend** | React with SSR, routing, i18n | `$page`, `$head`, `$atom`, `$dictionary` |
| **Platform** | Users, auth, jobs, audits | `$realm`, `$job`, `$audit`, `$notification` |
| **Admin** | Admin panel & auth UI | `$uiAdmin`, `$uiAuth` |
## Example
```tsx
// src/Api.ts
import { t } from "alepha";
import { $action } from "alepha/server";
import { $entity, $repository, db } from "alepha/orm";
const viewEntity = $entity({
name: "views",
schema: t.object({
id: db.primaryKey(),
createdAt: db.createdAt(),
}),
});
export class Api {
views = $repository(viewEntity);
inc = $action({
schema: { // ← validates + generates OpenAPI
response: t.object({
count: t.number()
})
},
handler: async () => {
await this.views.create({});
return { count: await this.views.count() };
},
});
}
```
```tsx
// src/AppRouter.tsx
import { $client } from "alepha/server/links";
import { $page } from "alepha/react/router";
import type { Api } from "./Api.ts";
export class AppRouter {
api = $client(); // ← fully typed, zero codegen
home = $page({
loader: () => this.api.inc(),
component: (props) =>
Counter: {props.count},
});
}
```
## Getting Started
Requirements: [Node.js](https://nodejs.org/) 22+ or [Bun](https://bun.sh/) 1.3+
```bash
npx alepha init my-app --api # L1: Backend only
--react # L2: + React frontend
--admin # L3: + Admin UI
cd my-app && npm run dev
```
## Learn More
- [Documentation](https://alepha.dev)
- [llms.txt](https://alepha.dev/llms.txt) — for AI assistants
- [GitHub](https://github.com/feunard/alepha)