The `github-api-emojis` package provides a static, pre-compiled list of emoji names available in the GitHub API. It exports two main structures: a flat array (`list`) containing all emoji names as strings, and an object (`map`) where emoji names are keys with a placeholder value (typically `1`) for efficient lookup. This library is designed for quick, synchronous access to GitHub emoji data without requiring any network requests. It is currently at version 1.0.4 and has a very slow release cadence, primarily for documentation updates or minor corrections, suggesting high stability. Its key differentiator is its minimal footprint and static nature, making it ideal for environments where a dynamic API call is unnecessary or undesired, and only the emoji names are required, not their images or full metadata.
npm install github-api-emojisVerified import paths — ran on the pinned version, not inferred.
This quickstart demonstrates how to import and use the emoji list and map, both from the main export and directly from their respective paths, for checking emoji existence and filtering.
Use `require()` syntax for imports or ensure your build pipeline correctly handles CommonJS module interop for ESM.
Periodically check for new package versions, especially if GitHub has recently added new emojis that your application requires.
When using `emojisMap`, only use it for boolean checks (e.g., `if (emojisMap[name])`) rather than expecting a specific data payload from the value.
Always specify the full path including `/lib/` when requiring specific exports: `require("github-api-emojis/lib/list")`.If in an ESM project, use dynamic `import()` or ensure your build setup correctly handles CommonJS modules. If using Node.js, ensure your file is treated as CommonJS (e.g., a `.js` file without `"type": "module"` in `package.json`, or a `.cjs` file).
Change the import path to `require("github-api-emojis/lib/list")` or `require("github-api-emojis/lib/map")`.Use the correct CommonJS `require` pattern: `const GitHubApiEmojis = require("github-api-emojis");` then access `GitHubApiEmojis.list`. If in ESM, try `import * as GitHubApiEmojis from 'github-api-emojis';` or stick to dynamic `import()`.No dependency data recorded yet.