Skip to main content

FormModel

Trait FormModel 

Source
pub trait FormModel {
    // Required methods
    fn form_fields() -> Vec<AutoField>;
    fn form_title() -> &'static str;
}
Expand description

Types that can describe their own form shape.

Invoked through the turbofish: FormBuilder::from_model::<User>() — no instance needed, so this composes with unit structs used purely as type tags.

Required Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§