Create Text Slugs In Rust
The slug crate is great for making urls and filenames from strings of text. For example:
use slugify;
Output:
this-is-the-test
Notes
-
Add the create with
cargo add slug
- Returns a-z, 0-9, and '-'
- never contain more than one '-'
- never start or end with '-'
-- end of line --