@jswork/kiv
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

kiv

Key includes value.

version license size download

installation

npm install @jswork/kiv

usage

import kiv from '@jswork/kiv';

const str2icon = {
  '@beta': '🍏',
  '@production': '🍎',
  '@upload': '🚚',
  '@cache': '📦',
};


kiv('Current msg is __@beta__.', str2icon); // Current msg is 🍏.
kiv('Current msg is __@production__.', str2icon); // Current msg is 🍎.
kiv('Current msg is __@upload__.', str2icon); // Current msg is 🚚.
kiv('Current msg is __@cache__.', str2icon); // Current msg is 📦.
kiv('Current msg is __@unknown__.', str2icon); // Current msg is ''.
kiv('Current msg is __@unknown__.', str2icon, '🍌'); // Current msg is 🍌.

license

Code released under the MIT license.

Readme

Keywords

Package Sidebar

Install

npm i @jswork/kiv

Homepage

js.work

Weekly Downloads

3

Version

1.0.2

License

MIT

Unpacked Size

5.1 kB

Total Files

7

Last publish

Collaborators

  • afeiship