An SMS message splitter with support for both GSM and Unicode written in JavaScript. GSM support is limited to GSM 03.38 with the extension table (see the Wikipedia article); no support for natural language shift tables exists at this time.
bash
cargo add sms_splitter
```rust use sms_splitter::SplitSms;
fn main(){
let info = SplitSms::default().split("Hello World!".tostring());
println!("{:#?}", info);
}
<!-- out put -->
text
SplitSmsResult {
characterset: "GSM",
parts: [
SplitterPart {
content: "Hello World!",
length: 12,
bytes: 12,
},
],
bytes: 12,
length: 12,
remaininginpart: 148,
}
```
A lot of the code in this package was based on Codesleuth split-sms
.