An iban validator containing rust generated WebAssembly
- Install the package as a JS dependency
npm i iban-validator - Import the validate function ex :
import { validate } from 'iban-validator';- Use it as any js function :
try {
this.isValid = validate(value)
} catch (e) {
// Handle error here
}ErrorNullValue: provided value is nullErrorMaxLength: the value is longer than 35 charErrorFirstTwoLetters: the first two letters should be strings (and match any country code - not implemented yet)ErrorChecksum: the checksum is invalidErrorMinLength: the value is shorter than 15 char