Add skip_serializing_if
when codegen
#647
Replies: 7 comments
-
We could, but this has to be opt-in. |
Beta Was this translation helpful? Give feedback.
-
Wonder what's your use case? Web API? |
Beta Was this translation helpful? Give feedback.
-
Opt-in is fine. |
Beta Was this translation helpful? Give feedback.
-
Yes, I build my web api with sea-orm and axum. |
Beta Was this translation helpful? Give feedback.
-
Do you want to implement it? I can guide you lolll |
Beta Was this translation helpful? Give feedback.
-
Ok, I will try to implement it. |
Beta Was this translation helpful? Give feedback.
-
Hey guys! Any updates here? :) |
Beta Was this translation helpful? Give feedback.
-
#[serde(skip_serialzing_if = "Option::is_none")]
is a very useful annotation used to skip serializing fields which values arenone
. How about considering to automatically add this annotation to fields with typeOption
in theModel
when codegen?Beta Was this translation helpful? Give feedback.
All reactions