From b85d4ce554b8e9195f412cbfafc06f576a534cf4 Mon Sep 17 00:00:00 2001 From: Dylan Bowker Date: Sun, 12 May 2024 14:19:52 -0600 Subject: [PATCH] docs: update to docs on codecs --- libraries/native_model/src/lib.rs | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/libraries/native_model/src/lib.rs b/libraries/native_model/src/lib.rs index 706872c4..1bfd8d7c 100644 --- a/libraries/native_model/src/lib.rs +++ b/libraries/native_model/src/lib.rs @@ -20,21 +20,22 @@ //! `native_model` comes with several optional built-in serializer features //! available: //! -//! - [bincode](https://crates.io/crates/bincode/1.3.3) `1.3` · This is the +//! - [bincode 1.3](https://crates.io/crates/bincode/1.3.3) · This is the //! default codec. **Warning: This codec may not work with all serde-derived //! types.** //! -//! - [bincode](https://crates.io/crates/bincode/2.0.0-rc.3) `2.0.0-rc.3` · +//! - [bincode 2.0.0-rc.3](https://crates.io/crates/bincode/2.0.0-rc.3) · //! Enable the `bincode_2_rc` feature and use the //! `native_model::bincode_2_rc::Bincode` attribute to have `native_db` use this -//! crate. **Warning: This codec may not work with all serde-derived types.** +//! crate for serializing & deserializing. **Warning: This codec may not work +//! with all serde-derived types.** //! -//! - [postcard](https://crates.io/crates/postcard/1.0.8) `1.0` · +//! - [postcard 1.0](https://crates.io/crates/postcard/1.0.8) · //! Enable the `postcard_1_0` feature and use the //! `native_model::postcard_1_0::PostCard` attribute. **Warning: This codec may //! not work with all serde-derived types.** //! -//! - [rmp-serde](https://crates.io/crates/rmp-serde/1.3.0) `1.3` · +//! - [rmp-serde 1.3](https://crates.io/crates/rmp-serde/1.3.0) · //! Enable the `rmp_serde_1_3` feature and use the //! `native_model::rmp_serde_1_3::RmpSerde` attribute. //! @@ -53,7 +54,8 @@ //! native_model = { version = "0.4", features = [ "rmp_serde_1_3" ] } //! ``` //! -//! 2. Assign the `rmp_serde_1_3` codec to your type using the `with` attribute: +//! 2. Assign the `rmp_serde_1_3` codec to your `struct` using the `with` +//! attribute: //! //! ```rust //! #[derive(Clone, Default, serde::Deserialize, serde::Serialize)]