Emojiis is a Go module that exposes a programmatic API to search and retrieve emoji icons using descriptive terms.
Version 2.0 uses a JSON file (from https://github.com/milesj/emojibase) for its dataset, containing all commonly used emojis.
The API has been updated (if you use v1.xx, some functions may break after you update).
Features:
- Ability to search the full set of common emojis
- Support for inclusion and exclusion search terms
- Ability to search by emoji tags
See our API documentation
To get started with the module, use the go get
command to pull down the packages:
go get github.com/celsopires1999/emojiis/v2@2.0.0
Here is a simple example of how to use the API:
emojis := search.ByDescription(search.Params{
Include: []string{"face"},
Exclude: []string{"smile", "laugh", "grin", "upside-down"}
})
Returns:
[]string{"🐵", "🐶", "🐱", "🐯", "🦊"}
Or, search by tags only:
emojis := search.ByTags("fruits")
Returns:
[]string{"🍇", "🍈", "🍉", "🍊", "🍋"}