str-chunks

Crates.iostr-chunks
lib.rsstr-chunks
version0.2.0
created_at2025-01-11 19:43:12.575842+00
updated_at2025-01-15 17:59:51.890691+00
descriptionimplements char-wise chunked iteration of str
homepage
repositoryhttps://github.com/barrowsys/str-chunks
max_upload_size
id1512617
size36,023
Ezra Barrow (barrowsys)

documentation

README

str-chunks

GitHub last commit Crates.io Docs.rs

About

implements char-wise chunked iteration of str

the methods str_chunks, str_chunks_exact, str_rchunks, and str_rchunks_exact behave like the similarly named methods on slice, but return string slices that are chunk_size chars long. take note: these slices are not necessarily chunk_size bytes long. chunk.len() != chunk_size

import ImplStrChunks to get methods on str

Usage

Add to your Cargo.toml:

[dependencies]
str-chunks = "0.1.1"

See docs.rs for examples.

or just copy [src/str_chunks.rs] into your own project. im not your mom. dont forget to remove the #![no_std]

Commit count: 5

cargo fmt