mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-05 08:07:21 +00:00
Generated the JSON contracts of the stored data at compile time (#1148)
This commit is contained in:
1 parent
fc7399e81b
commit
e954881fda
75 files changed
+5437
-298
No files matched your search
@@ -33,10 +33,10 @@ public sealed class ContentPresentation
|
||||
}
|
||||
}
|
||||
|
||||
internal static ContentPresentation Create<T>(ContentPresentationKind kind, T data) => new()
|
||||
internal static ContentPresentation Create<T>(ContentPresentationKind kind, T data, JsonSerializerOptions options) => new()
|
||||
{
|
||||
Kind = kind,
|
||||
Data = JsonSerializer.SerializeToElement(data),
|
||||
Data = JsonSerializer.SerializeToElement(data, options),
|
||||
};
|
||||
|
||||
internal ContentPresentation DeepClone() => new()
|
||||
|
||||
Reference in new issue
Block a user