Socket
Socket
Sign inDemoInstall

cdigit

Package Overview
Dependencies
1
Maintainers
1
Versions
54
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 3.2.0 to 3.2.1

example.js

3

package.json
{
"name": "cdigit",
"version": "3.2.0",
"version": "3.2.1",
"description": "Collection of check digit algorithms implemented in JavaScript",

@@ -15,2 +15,3 @@ "main": "lib/index.js",

"LICENSE-MIT",
"example.js",
"lib"

@@ -17,0 +18,0 @@ ],

@@ -126,2 +126,13 @@ # cdigit: Check Digit Algorithms in JS

### computeFromNumVals(numValsWithoutCheckChars: number[]): number[]
Generates the check character(s) from the argument using the algorithm. This
method is an alphabet-independent equivalent of `compute()`, where the return
value and argument are both represented as arrays of each digit's numerical
value.
```javascript
console.log(mod97_10.computeFromNumVals([1, 2, 3, 4])); // [8, 2]
```
See [example.js](https://npm.runkit.com/cdigit) for usage examples.

@@ -128,0 +139,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc