ls-enum
v0.3.2
Published
Tiny (208B) and fast utility to extract all possible values for a given enum.
Downloads
15
Readme
ls-enum
Tiny (208B) and fast utility to extract all possible values for a given enum.
Installation
Using yarn
yarn add ls-enum
Using pnpm
pnpm add ls-enum
Using npm
npm install ls-enum
Usage
import lsEnum from 'ls-enum';
enum TestEnum {
ValueOne = 'one',
ValueTwo = 2
};
const values = lsEnum(TestEnum); // <- ['one', 2]