-
-
Notifications
You must be signed in to change notification settings - Fork 61
Open
Description
It's Type impl is recursive. This will be fixed by #454
Repro:
use std::collections::HashMap;
use serde::Serialize;
use specta::{Type, TypeCollection};
use specta_typescript::Typescript;
#[derive(Serialize, Type)]
#[serde(rename_all = "camelCase")]
pub(crate) struct Policy {
#[serde(default, skip_serializing_if = "Option::is_none")]
configurations: Option<HashMap<String, serde_json::Value>>, // TODO: Fix Specta on value type
}
fn main() {
println!(
"{}",
Typescript::default()
.export(&TypeCollection::default().register::<Policy>())
.unwrap()
);
}for personal context: Found on Mattrax Policy.configurations and skipped for now.
We need better testing for custom impls!!!!
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels