Crate perseus[][src]

Re-exports

pub use http;
pub use crate::build::build_template;
pub use crate::build::build_templates;
pub use crate::config_manager::ConfigManager;
pub use crate::config_manager::FsConfigManager;
pub use crate::decode_time_str::decode_time_str;
pub use crate::errors::err_to_status_code;
pub use crate::errors::ErrorCause;
pub use crate::serve::get_page;
pub use crate::serve::get_render_cfg;
pub use crate::shell::app_shell;
pub use crate::shell::ErrorPages;
pub use crate::template::States;
pub use crate::template::StringResult;
pub use crate::template::StringResultWithCause;
pub use crate::template::Template;
pub use crate::template::TemplateMap;

Modules

Macros

Defines the components to create an entrypoint for the app. The actual entrypoint is created in the .perseus/ crate (where we can get all the dependencies without driving the user’s Cargo.toml nuts). This also defines the template map. This is intended to make compatibility with the Perseus CLI significantly easier.

An internal macro used for defining a function to get the user’s preferred config manager (which requires multiple branches).

Gets a HashMap of the given templates by their paths for serving. This should be manually wrapped for the pages your app provides for convenience.

Structs

Rendering backend for the DOM.

Represents an HTTP request.

Rendering backend for Server Side Rendering, aka. SSR.

Traits

Abstraction over a rendering backend.

Trait that is implemented for enums that can match routes.

Type Definitions

All HTTP requests use empty bodies for simplicity of passing them around. They’ll never need payloads (value in path requested).

Derive Macros

The Route procedural macro.