Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

codicefiscalejs-node

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

codicefiscalejs-node

A Node.js library to compute, validate and reverse Italian Tax Code (codice fiscale)

  • 0.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
9
increased by125%
Maintainers
1
Weekly downloads
 
Created
Source

CodiceFiscaleJS/Node

CodiceFiscaleJS/Node is a javascript and typescript utility library to compute and validate Italian Italian Tax code (codice fiscale). Inspired to CodiceFiscaleJS, it was rewritten from scratch for Node.js, in order to be faster (actually it's, on average, twice faster than CodiceFiscaleJS 🚄) and hopefully easier to use.

Don't fork, contribute!

Please, don't fork and republish this repository with silly minor changes! 😠 Please, give your contribution instead: any help is more than welcome!

Installation

Node

npm install @CodiceFiscaleJS/node --save

Usage

var {compute, reverse, validate} = require('@CodiceFiscaleJS/node');

const cf = compute({
    nome: 'Marco',
    cognome: 'Rossi',
    sesso: 'M',
    comune: 'Milano',
    provincia: 'MI',
    giorno: 1,
    mese: 1,
    anno: 1980   
}) // RSSMRC80A01F205Z


const userData = reverse("RSSMRC80A01F205Z")
/
*{
    nome: 'Marco',
    cognome: 'Rossi',
    sesso: 'M',
    comune: 'Milano',
    provincia: 'MI',
    giorno: 1,
    mese: 1,
    anno: 1980   
}
*/

const valid = isValid("RSSMRC80A01F205Z") // true
const notValid = isValid("ABCDEF12G34H567I") //false

TODO

  • Docs
  • Add Typescript types

Keywords

FAQs

Package last updated on 27 Sep 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc