inventory-unit-converter

1.0.3 • Public • Published

unit-converter

Unit converter basically used for developing inventory or SRM module in javascript

USES

Example

const unitConverter = require('inventory-unit-converter');

const units = [ {name:'Roll', parentId:0, unitId:1, isLowest:0, value:1}, {name:'Metter', parentId:1, unitId:2, isLowest:0, value:10}, {name:'Feet', parentId:2, unitId:3, isLowest:0, value:10}, {name:'Inches', parentId:3, unitId:4, isLowest:1, value:10} ];

const value = 5001;

unitConverter(value, units);

Result: 5 Roll, 1 Inches

Readme

Keywords

Package Sidebar

Install

npm i inventory-unit-converter

Weekly Downloads

23

Version

1.0.3

License

ISC

Unpacked Size

3.56 kB

Total Files

3

Last publish

Collaborators

  • nitin_vani_2024