Package Exports
- vies-validate
- vies-validate/lib/index.js
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 (vies-validate) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Getting started
Installation
npm install vies-validateUsage
import { validate } from "vies-validate";
const { data, error } = await validate("NL", "853746333B01");When valid:
data: {
countryCode: 'xx',
vatNumber: 'xxxxxxxxx',
requestDate: '2013-11-22+01:00',
valid: true,
name: 'company name',
address: 'company address'
}
error: nullWhen invalid:
data: {
countryCode: 'xx',
vatNumber: 'xxxxxxxxxx',
requestDate: '2013-11-22+01:00',
valid: false,
name: '---',
address: '---'
}
error: nullWhen error:
data: null;
error: "INVALID_INPUT";License
The MIT License (MIT)