elif_web/
lib.rs

1//! # elif.rs - The Rust web framework
2//!
3//! elif.rs is a modern web framework designed for both exceptional developer
4//! experience and AI-native development.
5//!
6//! This is the main umbrella package that provides a unified API and convenient
7//! imports for the entire elif.rs ecosystem.
8
9// Re-export all sub-packages as modules
10pub use elif_auth as auth;
11pub use elif_cache as cache;
12pub use elif_core as core;
13pub use elif_http as http;
14pub use elif_orm as orm;
15
16// Re-export common types at root level for convenience
17pub use elif_http::request::ElifRequest as Request;
18pub use elif_http::response::ElifResponse as Response;
19pub use elif_http::routing::ElifRouter as Router;
20pub use elif_http::Server;
21pub use elif_http::{HttpError, HttpResult};
22
23// Re-export core functionality
24pub use elif_core::{
25    ApiError, ApiErrorResponse, AppConfig, AppConfigTrait, BaseModule, ConfigSource, Container,
26    ContainerBuilder, CoreError, Environment, ErrorDefinition, Module, ModuleLoader,
27    ModuleRegistry, ProviderRegistry, ServiceProvider, ServiceRegistry, ServiceScope,
28};
29
30// Prelude module for convenient imports
31pub mod prelude;
32
33// Macro functionality - re-export from elif-macros crate
34pub use elif_macros as macros;
35pub use elif_macros::{bootstrap, main};
36
37// Re-export derive macros
38pub use elif_http_derive::{controller, module};
39
40/// Current version of elif.rs
41pub const VERSION: &str = env!("CARGO_PKG_VERSION");
42
43/// Framework information
44pub const FRAMEWORK_NAME: &str = "elif.rs";
45
46/// Get framework version
47pub fn version() -> &'static str {
48    VERSION
49}
50
51/// Get framework name
52pub fn name() -> &'static str {
53    FRAMEWORK_NAME
54}