@egjiri/node-kit
v1.7.0
Published
TypeScript/Javascript Utilities
Downloads
27
Readme
A collection of useful Node utility functions that can be used across projects. Written in TypeScript.
Installation
Install through npm:
npm install @egjiri/node-kit
Install through yarn:
yarn add @egjiri/node-kit
Usage Examples
import { formatNumber } from '@egjiri/node-kit/numbers'
formatNumber(1234.56, 'currency');
// => $1,234.56
import { removeKeysWithBlankValues } from '@egjiri/node-kit/objects'
removeKeysWithBlankValues({
first: 'first',
second: null,
third: undefined,
fourth: 4
});
// => { first: 'first', fourth: 4 }
Development
- Install dependencies:
yarn
- Run tests
yarn test
(tests automatically re-run when TypeScript src files change) - Start Coding!
Release
This project is released through GitHub Actions workflows that:
- Run the test suite and linters
- Build the TypeScript codebase into a build folder with JavaScript and TypeScript type definition files.
- Publish the build folder to the NPM Registry.