What is Elysia?

Ergonomic framework for Bun. End-to-end type safety with TypeBox integration.

Use the snippets below to quickly add common functionality to your Elysia applications. All snippets are production-ready and can be copied directly into your project.

Categories

Libraries

Core libraries and server setups

2 snippets

Plugins

Reusable Elysia plugins for common functionality

7 snippets

Middleware

Production middleware using Elysia's decorator patterns

7 snippets

Guards

Authentication and authorization guards using Elysia's beforeHandle hooks

4 snippets

Utilities

Utility functions and helpers for Elysia applications

6 snippets

Validation

Input validation patterns for Elysia applications

2 snippets

Routes

Common route patterns and factories for Elysia applications

2 snippets

Getting Started

Install the Hanma CLI to add snippets to your project:

npx hanma add  --framework elysia

Or browse the categories above to find the snippet you need.