@stdlib/datasets-emoji-code-picto

Emoji codes and pictographs.

Usage no npm install needed!

<script type="module">
  import stdlibDatasetsEmojiCodePicto from 'https://cdn.skypack.dev/@stdlib/datasets-emoji-code-picto';
</script>

README

Emoji Codes and Pictographs

NPM version Build Status Coverage Status

Map emoji codes to pictographs.

Installation

npm install @stdlib/datasets-emoji-code-picto

Usage

var table = require( '@stdlib/datasets-emoji-code-picto' );

table()

Returns an object mapping emoji codes to pictographs.

var t = table();
// returns {...}

var p = t[ ':smile:' ];
// returns '😄'

p = t[ ':unicorn:' ];
// returns '🦄'

Notes

Examples

var objectKeys = require( '@stdlib/utils-keys' );
var table = require( '@stdlib/datasets-emoji-code-picto' );

var codes;
var tbl;
var i;

// Get the data:
tbl = table();

// Get the emoji codes:
codes = objectKeys( tbl );

// Print out all the corresponding pictographs...
for ( i = 0; i < codes.length; i++ ) {
    console.log( codes[ i ] + ' => ' + tbl[ codes[ i ] ] );
}

CLI

Installation

To use the module as a general utility, install the module globally

npm install -g @stdlib/datasets-emoji-code-picto

Usage

Usage: emoji-code-picto [options]

Options:

  -h,    --help                Print this message.
  -V,    --version             Print the package version.

Notes

  • Data is written to stdout as comma-separated values (CSV), where the first line is a header line.
  • In contrast to the programmatic interface, some codes are duplicated, due to the inclusion of both emoji and text presentation emoji characters.

Examples

$ emoji-code-picto
code,emoji
...

License

The data files (databases) are licensed under an Open Data Commons Public Domain Dedication & License 1.0 and their contents are licensed under Creative Commons Zero v1.0 Universal. The software is licensed under Apache License, Version 2.0.


Notice

This package is part of stdlib, a standard library for JavaScript and Node.js, with an emphasis on numerical and scientific computing. The library provides a collection of robust, high performance libraries for mathematics, statistics, streams, utilities, and more.

For more information on the project, filing bug reports and feature requests, and guidance on how to develop stdlib, see the main project repository.

Community

Chat


Copyright

Copyright © 2016-2022. The Stdlib Authors.