# `compact_str`
**A memory efficient string type that can store up to 24\* bytes on the stack.**
[](https://crates.io/crates/compact_str)

[](./LICENSE)
[](https://github.com/ParkMyCar/compact_str/actions/workflows/ci.yml)
[](https://github.com/ParkMyCar/compact_str/actions/workflows/cross_platform.yml)
[](https://github.com/ParkMyCar/compact_str/actions/workflows/msrv.yml)
[](https://github.com/ParkMyCar/compact_str/actions/workflows/clippy.yml)
* 12 bytes for 32-bit architectures
### About
A `CompactString` is a more memory efficient string type, that can store smaller strings on the stack, and transparently stores longer strings on the heap (aka a small string optimization).
It can mostly be used as a drop in replacement for `String` and are particularly useful in parsing, deserializing, or any other application where you may
have smaller strings.
### Properties
A `CompactString` specifically has the following properties:
* `size_of::