Trait ToStringsExtension

Source
pub trait ToStringsExtension {
    // Required method
    fn strings(&self) -> Vec<String>;
}

Required Methods§

Source

fn strings(&self) -> Vec<String>

Converts a slice of string slices to a vector of strings. e.g. instead of

["1".to_string(), "2".to_string(), "3".to_string()];

you can do

use easier::prelude::*;
["1", "2", "3"].strings();

Implementations on Foreign Types§

Source§

impl ToStringsExtension for [&str]

Source§

fn strings(&self) -> Vec<String>

Implementors§