diff --git a/site/guide/5-responses.md b/site/guide/5-responses.md index c5bf662b..eda5c6b1 100644 --- a/site/guide/5-responses.md +++ b/site/guide/5-responses.md @@ -446,6 +446,8 @@ fn todo() -> Json { } ``` +! note: You must enable Rocket's `json` crate feature to use the [`Json`] type. + The `Json` type serializes the structure into JSON, sets the Content-Type to JSON, and emits the serialized data in a fixed-sized body. If serialization fails, a **500 - Internal Server Error** is returned.