Rust Rust Style Guide Creating Crates

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Extensions
> Step 2: And Like the video. BONUS: You can also share it!

Example

Preludes and Re-Exports

// To reduce the amount of imports that users need, you should
// re-export important structs and traits.
pub use foo::Client;
pub use bar::Server;

Sometimes, crates use a prelude module to contain important structs, just like std::io::prelude. Usually, these are imported with use std::io::prelude::*;



Got any Rust Question?