Crate rocket_modules
source · [−]Expand description
A small crate that adds macros to conveniently organize Rocket route handlers in modules.
This crate is not directly associated with the rocket project, although it is built upon it.
Usage
To use rocket_modules, add it to your dependencies in your Cargo.toml.
You should also add a dependency to rocket (version 0.5.0-rc2 or higher) if not already present:
[dependencies]
rocket = "0.5.0-rc.2"
rocket_modules = "0.1.0"Macros
Generates a Vec<rocket::Route> which contains all functions marked with a rocket route attribute. The module has to be marked with #[route_module].
Attribute Macros
Marks a module as route module which allows it to be passed as an argument to the module! macro.