zod_gen_derive

Crates.iozod_gen_derive
lib.rszod_gen_derive
version1.2.0
created_at2025-07-25 13:47:39.407582+00
updated_at2025-12-05 11:44:44.388785+00
descriptionDerive macro for zod_gen - automatically generate Zod schemas from Rust types with serde rename support
homepagehttps://github.com/cimatic/zod_gen
repositoryhttps://github.com/cimatic/zod_gen
max_upload_size
id1767629
size10,404
RSA (github:rustcrypto:rsa)

documentation

https://docs.rs/zod_gen

README

zod_gen_derive

Crates.io Documentation

Derive macro for zod_gen - automatically generate Zod schemas from Rust types.

Features

  • #[derive(ZodSchema)] procedural macro
  • Supports structs with named fields
  • Supports enums with unit variants
  • Automatic dependency resolution

Usage

use zod_gen::ZodSchema;
use zod_gen_derive::ZodSchema;

#[derive(ZodSchema)]
struct User {
    id: u64,
    name: String,
    is_admin: bool,
}

#[derive(ZodSchema)]
enum Status {
    Active,
    Inactive,
}

For more examples and documentation, see the main repository.

Commit count: 0

cargo fmt