[][src]Function voca_rs::case::capitalize

pub fn capitalize(subject: &str, rest_to_lower: bool) -> String

Converts the first character of subject to upper case. If restToLower is true, convert the rest of subject to lower case.

Arguments

Example

use voca_rs::*;
case::capitalize("green", true);
// => "Green"
case::capitalize("Say Hello to ME", true);
// => "Say hello to me"
use voca_rs::Voca;
"green"._capitalize(true);
// => "Green"