3 unstable releases

0.3.0 Jul 28, 2024
0.2.5 Jul 11, 2024
0.1.1 Jul 1, 2024
0.1.0 Jun 30, 2024

#1378 in Development tools

Download history 217/week @ 2024-06-25 249/week @ 2024-07-02 349/week @ 2024-07-09 1/week @ 2024-07-16 97/week @ 2024-07-23 25/week @ 2024-07-30

565 downloads per month
Used in 2 crates

MIT license

8KB
194 lines

essentials

useful structs functions for rustaceans

Usage

let our crate make a important role in your project!

essentials currently unstable version,
everything may refactoring in anytime.
think twice if you intend it into your important projects!

[dependencies]
essentials = "0.3.0"

view github to download the source code and official builds.

Featurs

  • shotcuts for common functions
let result: Result<&str,&str> = Err("error");
let option: Option<&str> = None;

let result = result.summary( |_| "default" );
let option = option.summary( | | "default" );

println!("result: {result}");
println!("option: {option}");
  • useful structs which missing in std lib
/// actions may be failure
pub fn execute()-> Reason<String>
{
    return Success;
}

let result = execute();
result.on_success(| | println!("success"));
result.on_failure(|e| println!("fail for {e}"));

Document

none document published yet but comming soon

No runtime deps

Features