pub fn type_name<T: ?Sized + 'static>() -> StringExpand description
Get the human-friendly type name of given type T, removing visual clutter such as
full module paths.
ยงExamples
use pretty_name::type_name;
assert_eq!(type_name::<Option<i32>>(), "Option<i32>");
assert_eq!(type_name::<&str>(), "&str");
assert_eq!(type_name::<Vec<Box<dyn std::fmt::Debug>>>(), "Vec<Box<dyn Debug>>");