hotaru_meta 0.7.2

Core macros for Hotaru
Documentation

hotaru_meta

Crates.io

Procedural macros for the Hotaru web framework, providing declarative syntax for endpoint and middleware definition.

Macros

endpoint!

Define HTTP endpoints with automatic registration:

use hotaru_meta::endpoint;

endpoint! {
    APP.url("/api/users"),
    pub handle_users<HTTP> {
        text_response("User list")
    }
}

middleware!

Define middleware with clean syntax:

use hotaru_meta::middleware;

middleware! {
    pub AuthMiddleware<HTTP> {
        // Middleware implementation
    }
}

Features

  • Declarative endpoint registration
  • Protocol-generic middleware definition
  • Compile-time route validation
  • Automatic handler wrapping
  • Zero runtime overhead

Usage

This crate is automatically included when using the Hotaru framework. You typically don't need to add it directly.

License

GPL-3.0 License

Part of Hotaru Framework

This is the macro crate for the Hotaru web framework.

Learn more: https://fds.rs