JSPM

percentage-value

1.0.4
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1
  • Score
    100M100P100Q39104F
  • License ISC

Percentage converting helper functions

Package Exports

  • percentage-value

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (percentage-value) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Percantage-value

Description

Simple percentage calculations.

☁️ Installation

$ npm i --save percent-value

or

<script src="percantage-value.js"></script>

Usage

const percentage = require('percantage-value');

Examples

For calculating how much is a percent of a number, use the of method:

percentage.of(50, 100); // will return 50

If you'd like to calculate percent of a number from another number, use the from method:

percentage.from(70, 100); // will return 70

Enjoy!