Trait heck::ToKebabCase[][src]

pub trait ToKebabCase: ToOwned {
    fn to_kebab_case(&self) -> Self::Owned;
Expand description

This trait defines a kebab case conversion.

In kebab-case, word boundaries are indicated by hyphens.


use heck::ToKebabCase;

let sentence = "We are going to inherit the earth.";
assert_eq!(sentence.to_kebab_case(), "we-are-going-to-inherit-the-earth");

Required methods

Convert this type to kebab case.

Implementations on Foreign Types