Coder Social home page Coder Social logo

stvkoch / node-iso7064-mod9710 Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 0.0 5 KB

Calculate and validate check digits following Norma ISO 7064 Mod 97-10 such as IBAN and NIB validation

License: MIT License

JavaScript 100.00%
iso7064 mod9710 node npm-package iban iban-validator iban-checker

node-iso7064-mod9710's Introduction

Iso7064 Mod 97 10 Build Status

Calculate and validate numbers to avoid types mistakes, common used by IBAN and NIB.

Install

$ npm install node-iso7064-mod9710

Usage

import Mod9710 from 'node-iso7064-mod9710';

Mod9710.encode('794');
//=> 79444

Mod9710.verify('79444');
//=> true

Mod9710.verify('79544');
//=> false

Mod9710.getCheck('79444');
//=> 44

Mod9710.getData('79444');
//=> 794

Mod9710.checkCode('794');
//=> 44

API

verify(number : string) : boolean

Verify if the number is a valid number, well typed.

number

Type: string

IBAN or NIB number or any number generated with check digit mod97-10

encode(number : string) : string

Encode the number with a check digits

number

Type: string

IBAN or NIB number or any number generated with check digit mod97-10

getCheck(number : string) : string

Return the check digits computed by encode method

number

Type: string

IBAN or NIB number or any number generated with check digit mod97-10

getData(number : string) : string

Return the number without the check digit

number

Type: string

IBAN or NIB number or any number generated with check digit mod97-10

node-iso7064-mod9710's People

Contributors

skoch-tf avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.