Skip to content

tonipepperoni/gello-framework

Repository files navigation

Gello

The Effect-powered backend framework
Laravel's elegance meets Effect's type safety. No decorators, no magic—just functions.

npm version npm downloads license Effect

DocumentationInstallationCLI


Why Gello?

Gello combines the developer experience of Laravel with the type safety of Effect. No decorators, no magic—just functions and values.

// Define a service
class UserRepo extends Context.Tag("UserRepo")<UserRepo, {
  findById: (id: string) => Effect.Effect<User, NotFoundError>
}>() {}

// Use it in a route
route.get("/users/:id", Effect.gen(function* () {
  const { id } = yield* Route.params
  const repo = yield* UserRepo
  const user = yield* repo.findById(id)
  return Response.json(user)
}))

What you get:

  • Compile-time error tracking — know exactly what can fail
  • Automatic dependency injection — yield* from context
  • Resource safety — connections close, pools drain
  • Testability — swap any Layer for a mock

Quick Start

npx gello new my-app
cd my-app
pnpm install
pnpm dev

Your server is running at http://localhost:3000.

Features

Feature Description
Effect Core Type-safe errors, dependency injection, resource management
HTTP Server Built on @effect/platform with typed routing and middleware
Validation Schema validation with @effect/schema at boundaries
Database Drizzle ORM with Effect-managed connection pools
Queues Pure Effect job queues — no Redis required
Mail Email sending with React templates
Auth Authentication, authorization, OAuth providers
CLI Project scaffolding, dev server, route inspection

Packages

# Core framework
pnpm add @gello/core @gello/common @gello/platform-node

# Optional
pnpm add @gello/queue      # Job queues
pnpm add @gello/mail       # Email sending
pnpm add @gello/auth       # Authentication
pnpm add @gello/fp         # Optics, refined types
pnpm add -D @gello/testing # Test utilities
Package Description
@gello/core Contracts, errors, base types
@gello/common Middleware, routing, validation
@gello/platform-node Node.js HTTP adapter
@gello/queue Effect-native queue system
@gello/mail Email with React templates
@gello/auth Authentication & authorization
@gello/fp Optics, refined types
@gello/testing Mocks and test utilities

Example

import { Effect, Layer } from "effect"
import { NodeServer, route, Route, Response } from "@gello/platform-node"

// Define routes
const routes = Route.group({ prefix: "/api" }, [
  route.get("/", Effect.succeed(Response.json({ status: "ok" }))),

  route.get("/users/:id", Effect.gen(function* () {
    const { id } = yield* Route.params
    return Response.json({ id })
  }))
])

// Start server
NodeServer.make({ port: 3000 })
  .pipe(
    Layer.provide(routes),
    Layer.launch,
    Effect.runPromise
  )

CLI

npx gello new my-app      # Create new project
npx gello serve           # Start dev server with hot reload
npx gello route:list      # Display registered routes

Documentation

Full documentation at gello.net/docs

Contributing

Contributions welcome! Please see CONTRIBUTING.md for guidelines.

License

MIT License. See LICENSE for details.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors