Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/badboy/base-emoji-rs
Output a buffer ([0xde, 0xad, 0xbe, 0xef]) in emojis ("οΈπΌ π π
)
https://github.com/badboy/base-emoji-rs
Last synced: 9 days ago
JSON representation
Output a buffer ([0xde, 0xad, 0xbe, 0xef]) in emojis ("οΈπΌ π π )
- Host: GitHub
- URL: https://github.com/badboy/base-emoji-rs
- Owner: badboy
- License: mit
- Created: 2017-06-03T12:35:16.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-10-04T11:15:30.000Z (over 5 years ago)
- Last Synced: 2024-12-24T02:01:06.824Z (12 days ago)
- Language: Rust
- Size: 17.6 KB
- Stars: 6
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# base_emoji
[![crates.io](http://meritbadge.herokuapp.com/base_emoji)](https://crates.io/crates/base_emoji)
[![Build Status](https://travis-ci.org/badboy/base-emoji-rs.svg?branch=master)](https://travis-ci.org/badboy/base-emoji-rs)Convert everything to Emojis (and back)!
π«π¦π₯π²π¬ππππ¬π²π¬ππππ§ππ₯πͺπππ¦πππ£π¦πππ€π
Reimplementation of [base_emoji](https://github.com/pfrazee/base-emoji) (JavaScript).
## Documentation
[Documentation available online](https://docs.rs/base_emoji).
## Example
```rust
let input = [0xde, 0xad, 0xbe, 0xef];
let output = "βοΈπΌππ ";assert_eq!(base_emoji::to_string(&input), output);
```## Encoding (same as original implementation)
Citing [the README](https://github.com/pfrazee/base-emoji/blob/04b6c1e24ae5071804285cb358162628ea4a9bc8/README.md):
> The emojis used are in `emojis.json`. There are 843 emojis there, but the
> converter reads sequences of 8 bits at a time, and so only maps the value to
> the first 256 of them. To stay consistent with other renderings, make sure you
> don't change the order of your emojis.json.## Decoding
Decoding requires the use of only the same 256 emojis used above.
## License
MIT. See [LICENSE](LICENSE).