ngx-iban-validator 1.1.3 → 1.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +132 -93
- package/dist/README.md +253 -0
- package/dist/iban.validator.js +52 -19
- package/dist/iban.validator.spec.js +277 -206
- package/dist/index.js +1 -5
- package/jest.config.js +6 -0
- package/package.json +5 -7
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# IBAN Validator
|
|
2
2
|
|
|
3
|
-
IBAN Validator for your reactive Angular forms, comes without any dependencies and can be used even outside of Angular as standalone function in any JS project. It can perform format, digit and length IBAN validations. Currently supports
|
|
3
|
+
IBAN Validator for your reactive Angular forms, comes without any dependencies and can be used even outside of Angular as standalone function in any JS project. It can perform format, digit and length IBAN validations. Currently supports 105 countries
|
|
4
4
|
|
|
5
5
|
## Install
|
|
6
6
|
|
|
@@ -13,15 +13,15 @@ npm install ngx-iban-validator --save
|
|
|
13
13
|
Import validateIBAN function from ngx-iban-validator package into your component file. Add validateIBAN to your form validators array.
|
|
14
14
|
|
|
15
15
|
```typescript
|
|
16
|
-
import { Component, OnInit } from
|
|
17
|
-
import { FormBuilder, FormGroup, Validators } from
|
|
16
|
+
import { Component, OnInit } from "@angular/core";
|
|
17
|
+
import { FormBuilder, FormGroup, Validators } from "@angular/forms";
|
|
18
18
|
|
|
19
|
-
import { validateIBAN } from
|
|
19
|
+
import { validateIBAN } from "ngx-iban-validator";
|
|
20
20
|
|
|
21
21
|
@Component({
|
|
22
|
-
selector:
|
|
23
|
-
templateUrl:
|
|
24
|
-
styleUrls: [
|
|
22
|
+
selector: "app-root",
|
|
23
|
+
templateUrl: "./app.component.html",
|
|
24
|
+
styleUrls: ["./app.component.scss"],
|
|
25
25
|
})
|
|
26
26
|
export class AppComponent implements OnInit {
|
|
27
27
|
ibanForm: FormGroup;
|
|
@@ -30,7 +30,7 @@ export class AppComponent implements OnInit {
|
|
|
30
30
|
|
|
31
31
|
ngOnInit() {
|
|
32
32
|
this.ibanForm = this.formBuilder.group({
|
|
33
|
-
iban: [
|
|
33
|
+
iban: ["", [Validators.required, validateIBAN]],
|
|
34
34
|
});
|
|
35
35
|
}
|
|
36
36
|
}
|
|
@@ -80,102 +80,129 @@ You can use validateIBAN function independently from any forms. Function will ch
|
|
|
80
80
|
|
|
81
81
|
```typescript
|
|
82
82
|
const ibanIsInvalid = validateIBAN({
|
|
83
|
-
value:
|
|
83
|
+
value: "AL35202111090000000001234567",
|
|
84
84
|
}).ibanInvalid;
|
|
85
85
|
```
|
|
86
86
|
|
|
87
87
|
# NodeJS
|
|
88
88
|
|
|
89
89
|
```javascript
|
|
90
|
-
const ibanValidator = require(
|
|
90
|
+
const ibanValidator = require("ngx-iban-validator");
|
|
91
91
|
const ibanIsInvalid = ibanValidator.validateIBAN({
|
|
92
|
-
value:
|
|
92
|
+
value: "BA393385804800211234",
|
|
93
93
|
}).ibanInvalid;
|
|
94
94
|
```
|
|
95
95
|
|
|
96
96
|
# Supported countries
|
|
97
97
|
|
|
98
|
-
| Country
|
|
99
|
-
|
|
|
100
|
-
| Albania
|
|
101
|
-
|
|
|
102
|
-
|
|
|
103
|
-
|
|
|
104
|
-
|
|
|
105
|
-
|
|
|
106
|
-
|
|
|
107
|
-
|
|
|
108
|
-
|
|
|
109
|
-
|
|
|
110
|
-
|
|
|
111
|
-
|
|
|
112
|
-
|
|
|
113
|
-
|
|
|
114
|
-
|
|
|
115
|
-
|
|
|
116
|
-
|
|
|
117
|
-
|
|
|
118
|
-
|
|
|
119
|
-
|
|
|
120
|
-
|
|
|
121
|
-
|
|
|
122
|
-
|
|
|
123
|
-
|
|
|
124
|
-
|
|
|
125
|
-
|
|
|
126
|
-
|
|
|
127
|
-
|
|
|
128
|
-
|
|
|
129
|
-
|
|
|
130
|
-
|
|
|
131
|
-
|
|
|
132
|
-
|
|
|
133
|
-
|
|
|
134
|
-
|
|
|
135
|
-
|
|
|
136
|
-
|
|
|
137
|
-
|
|
|
138
|
-
|
|
|
139
|
-
|
|
|
140
|
-
|
|
|
141
|
-
|
|
|
142
|
-
|
|
|
143
|
-
|
|
|
144
|
-
|
|
|
145
|
-
|
|
|
146
|
-
|
|
|
147
|
-
|
|
|
148
|
-
|
|
|
149
|
-
|
|
|
150
|
-
|
|
|
151
|
-
|
|
|
152
|
-
|
|
|
153
|
-
|
|
|
154
|
-
|
|
|
155
|
-
|
|
|
156
|
-
|
|
|
157
|
-
|
|
|
158
|
-
|
|
|
159
|
-
|
|
|
160
|
-
|
|
|
161
|
-
|
|
|
162
|
-
|
|
|
163
|
-
|
|
|
164
|
-
|
|
|
165
|
-
|
|
|
166
|
-
|
|
|
167
|
-
|
|
|
168
|
-
|
|
|
169
|
-
|
|
|
170
|
-
|
|
|
171
|
-
|
|
|
172
|
-
|
|
|
173
|
-
|
|
|
174
|
-
|
|
|
175
|
-
|
|
|
176
|
-
|
|
|
177
|
-
|
|
|
178
|
-
|
|
|
98
|
+
| Country | Country Code | Length |
|
|
99
|
+
| ------------------------ | ------------ | ------ |
|
|
100
|
+
| Albania | AL | 28 |
|
|
101
|
+
| Algeria | DZ | 26 |
|
|
102
|
+
| Andorra | AD | 24 |
|
|
103
|
+
| Angola | AO | 25 |
|
|
104
|
+
| Austria | AT | 20 |
|
|
105
|
+
| Azerbaijan | AZ | 28 |
|
|
106
|
+
| Bahrain | BH | 22 |
|
|
107
|
+
| Belarus | BY | 28 |
|
|
108
|
+
| Belgium | BE | 16 |
|
|
109
|
+
| Benin | BJ | 28 |
|
|
110
|
+
| Bosnia and Herzegovina | BA | 20 |
|
|
111
|
+
| Brazil | BR | 29 |
|
|
112
|
+
| Bulgaria | BG | 22 |
|
|
113
|
+
| Burundi | BI | 16 |
|
|
114
|
+
| Burkina Faso | BF | 28 |
|
|
115
|
+
| Cameroon | CM | 27 |
|
|
116
|
+
| Cape Verde | CV | 25 |
|
|
117
|
+
| Central African Republic | CF | 27 |
|
|
118
|
+
| Chad | TD | 27 |
|
|
119
|
+
| Comoros | KM | 27 |
|
|
120
|
+
| Congo | CG | 27 |
|
|
121
|
+
| Costa Rica | CR | 22 |
|
|
122
|
+
| Croatia | HR | 21 |
|
|
123
|
+
| Cyprus | CY | 28 |
|
|
124
|
+
| Czech Republic | CZ | 24 |
|
|
125
|
+
| Denmark | DK | 18 |
|
|
126
|
+
| Dominican Republic | DO | 28 |
|
|
127
|
+
| Egypt | EG | 29 |
|
|
128
|
+
| El Salvador | SV | 28 |
|
|
129
|
+
| Equatorial Guinea | GQ | 27 |
|
|
130
|
+
| Estonia | EE | 20 |
|
|
131
|
+
| Faroe Islands | FO | 18 |
|
|
132
|
+
| Finland | FI | 18 |
|
|
133
|
+
| France | FR | 27 |
|
|
134
|
+
| Gabon | GA | 27 |
|
|
135
|
+
| Georgia | GE | 22 |
|
|
136
|
+
| Germany | DE | 22 |
|
|
137
|
+
| Gibraltar | GI | 23 |
|
|
138
|
+
| Greece | GR | 27 |
|
|
139
|
+
| Greenland | GL | 18 |
|
|
140
|
+
| Guatemala | GT | 28 |
|
|
141
|
+
| Guinea-Bissau | GW | 25 |
|
|
142
|
+
| Vatican | VA | 22 |
|
|
143
|
+
| Honduras | HN | 28 |
|
|
144
|
+
| Hungary | HU | 28 |
|
|
145
|
+
| Iceland | IS | 26 |
|
|
146
|
+
| Iran | IR | 26 |
|
|
147
|
+
| Iraq | IQ | 23 |
|
|
148
|
+
| Ireland | IE | 22 |
|
|
149
|
+
| Israel | IL | 23 |
|
|
150
|
+
| Italy | IT | 27 |
|
|
151
|
+
| Ivory Coast | CI | 28 |
|
|
152
|
+
| Jordan | JO | 30 |
|
|
153
|
+
| Kazakhstan | KZ | 20 |
|
|
154
|
+
| Kosovo | XK | 20 |
|
|
155
|
+
| Kuwait | KW | 30 |
|
|
156
|
+
| Latvia | LV | 21 |
|
|
157
|
+
| Lebanon | LB | 28 |
|
|
158
|
+
| Libya | LY | 25 |
|
|
159
|
+
| Liechtenstein | LI | 21 |
|
|
160
|
+
| Lithuania | LT | 20 |
|
|
161
|
+
| Luxembourg | LU | 20 |
|
|
162
|
+
| Madagascar | MG | 27 |
|
|
163
|
+
| Mali | ML | 28 |
|
|
164
|
+
| Malta | MT | 31 |
|
|
165
|
+
| Mauritania | MR | 27 |
|
|
166
|
+
| Mauritius | MU | 30 |
|
|
167
|
+
| Moldova | MD | 24 |
|
|
168
|
+
| Monaco | MC | 27 |
|
|
169
|
+
| Mongolia | MN | 20 |
|
|
170
|
+
| Montenegro | ME | 22 |
|
|
171
|
+
| Morocco | MA | 28 |
|
|
172
|
+
| Mozambique | MZ | 25 |
|
|
173
|
+
| Netherlands | NL | 18 |
|
|
174
|
+
| Nicaragua | NI | 32 |
|
|
175
|
+
| Niger | NE | 28 |
|
|
176
|
+
| North Macedonia | MK | 19 |
|
|
177
|
+
| Norway | NO | 15 |
|
|
178
|
+
| Pakistan | PK | 24 |
|
|
179
|
+
| Palestine | PS | 29 |
|
|
180
|
+
| Poland | PL | 28 |
|
|
181
|
+
| Portugal | PT | 25 |
|
|
182
|
+
| Qatar | QA | 29 |
|
|
183
|
+
| Romania | RO | 24 |
|
|
184
|
+
| Russia | RU | 33 |
|
|
185
|
+
| Saint Lucia | LC | 32 |
|
|
186
|
+
| San Marino | SM | 27 |
|
|
187
|
+
| Sao Tome and Principe | ST | 25 |
|
|
188
|
+
| Saudi Arabia | SA | 24 |
|
|
189
|
+
| Senegal | SN | 28 |
|
|
190
|
+
| Serbia | RS | 22 |
|
|
191
|
+
| Seychelles | SC | 31 |
|
|
192
|
+
| Slovak Republic | SK | 24 |
|
|
193
|
+
| Slovenia | SI | 19 |
|
|
194
|
+
| Spain | ES | 24 |
|
|
195
|
+
| Sudan | SD | 18 |
|
|
196
|
+
| Sweden | SE | 24 |
|
|
197
|
+
| Switzerland | CH | 21 |
|
|
198
|
+
| Timor-Leste | TL | 23 |
|
|
199
|
+
| Togo | TG | 28 |
|
|
200
|
+
| Tunisia | TN | 24 |
|
|
201
|
+
| Turkey | TR | 26 |
|
|
202
|
+
| Ukraine | UA | 29 |
|
|
203
|
+
| United Arab Emirates | AE | 23 |
|
|
204
|
+
| United Kingdom | GB | 22 |
|
|
205
|
+
| Virgin Islands, British | VG | 24 |
|
|
179
206
|
|
|
180
207
|
# Development
|
|
181
208
|
|
|
@@ -197,9 +224,21 @@ npm run test
|
|
|
197
224
|
npx tsc
|
|
198
225
|
```
|
|
199
226
|
|
|
227
|
+
# v 1.1.5
|
|
228
|
+
|
|
229
|
+
Added additional pattern validation
|
|
230
|
+
Added more tests to improve test coverage
|
|
231
|
+
Added support for new countries: Algeria, Angola, Benin, Burkina Faso, Burundi, Cameroon, Cape Verde, Central African Republic, Chad, Comoros, Congo, Equatorial Guinea, Gabon, Guinea-Bissau, Honduras, Iran, Ivory Coast, Madagascar, Mali, Mongolia, Morocco, Mozambique, Nicaragua, Niger, Russia, Senegal, Togo
|
|
232
|
+
|
|
233
|
+
# v 1.1.4
|
|
234
|
+
|
|
235
|
+
Avoid Angular warnings for old CommonJS module usage (see https://angular.io/guide/build#configuring-commonjs-dependencies)
|
|
236
|
+
|
|
237
|
+
Replaced mocha and chai with JEST for tests
|
|
238
|
+
|
|
200
239
|
# v 1.1.3
|
|
201
240
|
|
|
202
|
-
Added support for new countries Vatican, Libya, Sao Tome and Principe, Sudan
|
|
241
|
+
Added support for new countries: Vatican, Libya, Sao Tome and Principe, Sudan
|
|
203
242
|
Updated length for LC Saint Lucia from 30 to 32
|
|
204
243
|
|
|
205
244
|
Added Tests
|
package/dist/README.md
ADDED
|
@@ -0,0 +1,253 @@
|
|
|
1
|
+
# IBAN Validator
|
|
2
|
+
|
|
3
|
+
IBAN Validator for your reactive Angular forms, comes without any dependencies and can be used even outside of Angular as standalone function in any JS project. It can perform format, digit and length IBAN validations. Currently supports 105 countries
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install ngx-iban-validator --save
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Use as a form validator
|
|
12
|
+
|
|
13
|
+
Import validateIBAN function from ngx-iban-validator package into your component file. Add validateIBAN to your form validators array.
|
|
14
|
+
|
|
15
|
+
```typescript
|
|
16
|
+
import { Component, OnInit } from "@angular/core";
|
|
17
|
+
import { FormBuilder, FormGroup, Validators } from "@angular/forms";
|
|
18
|
+
|
|
19
|
+
import { validateIBAN } from "ngx-iban-validator";
|
|
20
|
+
|
|
21
|
+
@Component({
|
|
22
|
+
selector: "app-root",
|
|
23
|
+
templateUrl: "./app.component.html",
|
|
24
|
+
styleUrls: ["./app.component.scss"],
|
|
25
|
+
})
|
|
26
|
+
export class AppComponent implements OnInit {
|
|
27
|
+
ibanForm: FormGroup;
|
|
28
|
+
|
|
29
|
+
constructor(private formBuilder: FormBuilder) {}
|
|
30
|
+
|
|
31
|
+
ngOnInit() {
|
|
32
|
+
this.ibanForm = this.formBuilder.group({
|
|
33
|
+
iban: ["", [Validators.required, validateIBAN]],
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
## Display error
|
|
40
|
+
|
|
41
|
+
Validator is returning object as result of checks.
|
|
42
|
+
|
|
43
|
+
```typescript
|
|
44
|
+
export interface IBANValidationResult {
|
|
45
|
+
ibanInvalid: boolean;
|
|
46
|
+
error: IBANError;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface IBANError {
|
|
50
|
+
countryUnsupported: boolean;
|
|
51
|
+
codeLengthInvalid: boolean;
|
|
52
|
+
patternInvalid: boolean;
|
|
53
|
+
}
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Error object contains more details about validation error. You can display errors easily as with any other validator.
|
|
57
|
+
|
|
58
|
+
```html
|
|
59
|
+
<form [formGroup]="ibanForm">
|
|
60
|
+
<input type="text" formControlName="iban" />
|
|
61
|
+
<small
|
|
62
|
+
*ngIf="ibanForm.get('iban').errors && ibanForm.get('iban').errors.ibanInvalid"
|
|
63
|
+
>
|
|
64
|
+
<span *ngIf="ibanForm.get('iban').errors.error.countryUnsupported">
|
|
65
|
+
Country not supported
|
|
66
|
+
</span>
|
|
67
|
+
<span *ngIf="ibanForm.get('iban').errors.error.codeLengthInvalid">
|
|
68
|
+
IBAN Code length is invalid
|
|
69
|
+
</span>
|
|
70
|
+
<span *ngIf="ibanForm.get('iban').errors.error.patternInvalid">
|
|
71
|
+
IBAN Code pattern is invalid
|
|
72
|
+
</span>
|
|
73
|
+
</small>
|
|
74
|
+
</form>
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
## Use as standalone function
|
|
78
|
+
|
|
79
|
+
You can use validateIBAN function independently from any forms. Function will check IBAN and return object { ibanInvalid: boolean }
|
|
80
|
+
|
|
81
|
+
```typescript
|
|
82
|
+
const ibanIsInvalid = validateIBAN({
|
|
83
|
+
value: "AL35202111090000000001234567",
|
|
84
|
+
}).ibanInvalid;
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
# NodeJS
|
|
88
|
+
|
|
89
|
+
```javascript
|
|
90
|
+
const ibanValidator = require("ngx-iban-validator");
|
|
91
|
+
const ibanIsInvalid = ibanValidator.validateIBAN({
|
|
92
|
+
value: "BA393385804800211234",
|
|
93
|
+
}).ibanInvalid;
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
# Supported countries
|
|
97
|
+
|
|
98
|
+
| Country | Country Code | Length |
|
|
99
|
+
| ------------------------ | ------------ | ------ |
|
|
100
|
+
| Albania | AL | 28 |
|
|
101
|
+
| Algeria | DZ | 26 |
|
|
102
|
+
| Andorra | AD | 24 |
|
|
103
|
+
| Angola | AO | 25 |
|
|
104
|
+
| Austria | AT | 20 |
|
|
105
|
+
| Azerbaijan | AZ | 28 |
|
|
106
|
+
| Bahrain | BH | 22 |
|
|
107
|
+
| Belarus | BY | 28 |
|
|
108
|
+
| Belgium | BE | 16 |
|
|
109
|
+
| Benin | BJ | 28 |
|
|
110
|
+
| Bosnia and Herzegovina | BA | 20 |
|
|
111
|
+
| Brazil | BR | 29 |
|
|
112
|
+
| Bulgaria | BG | 22 |
|
|
113
|
+
| Burundi | BI | 16 |
|
|
114
|
+
| Burkina Faso | BF | 28 |
|
|
115
|
+
| Cameroon | CM | 27 |
|
|
116
|
+
| Cape Verde | CV | 25 |
|
|
117
|
+
| Central African Republic | CF | 27 |
|
|
118
|
+
| Chad | TD | 27 |
|
|
119
|
+
| Comoros | KM | 27 |
|
|
120
|
+
| Congo | CG | 27 |
|
|
121
|
+
| Costa Rica | CR | 22 |
|
|
122
|
+
| Croatia | HR | 21 |
|
|
123
|
+
| Cyprus | CY | 28 |
|
|
124
|
+
| Czech Republic | CZ | 24 |
|
|
125
|
+
| Denmark | DK | 18 |
|
|
126
|
+
| Dominican Republic | DO | 28 |
|
|
127
|
+
| Egypt | EG | 29 |
|
|
128
|
+
| El Salvador | SV | 28 |
|
|
129
|
+
| Equatorial Guinea | GQ | 27 |
|
|
130
|
+
| Estonia | EE | 20 |
|
|
131
|
+
| Faroe Islands | FO | 18 |
|
|
132
|
+
| Finland | FI | 18 |
|
|
133
|
+
| France | FR | 27 |
|
|
134
|
+
| Gabon | GA | 27 |
|
|
135
|
+
| Georgia | GE | 22 |
|
|
136
|
+
| Germany | DE | 22 |
|
|
137
|
+
| Gibraltar | GI | 23 |
|
|
138
|
+
| Greece | GR | 27 |
|
|
139
|
+
| Greenland | GL | 18 |
|
|
140
|
+
| Guatemala | GT | 28 |
|
|
141
|
+
| Guinea-Bissau | GW | 25 |
|
|
142
|
+
| Vatican | VA | 22 |
|
|
143
|
+
| Honduras | HN | 28 |
|
|
144
|
+
| Hungary | HU | 28 |
|
|
145
|
+
| Iceland | IS | 26 |
|
|
146
|
+
| Iran | IR | 26 |
|
|
147
|
+
| Iraq | IQ | 23 |
|
|
148
|
+
| Ireland | IE | 22 |
|
|
149
|
+
| Israel | IL | 23 |
|
|
150
|
+
| Italy | IT | 27 |
|
|
151
|
+
| Ivory Coast | CI | 28 |
|
|
152
|
+
| Jordan | JO | 30 |
|
|
153
|
+
| Kazakhstan | KZ | 20 |
|
|
154
|
+
| Kosovo | XK | 20 |
|
|
155
|
+
| Kuwait | KW | 30 |
|
|
156
|
+
| Latvia | LV | 21 |
|
|
157
|
+
| Lebanon | LB | 28 |
|
|
158
|
+
| Libya | LY | 25 |
|
|
159
|
+
| Liechtenstein | LI | 21 |
|
|
160
|
+
| Lithuania | LT | 20 |
|
|
161
|
+
| Luxembourg | LU | 20 |
|
|
162
|
+
| Madagascar | MG | 27 |
|
|
163
|
+
| Mali | ML | 28 |
|
|
164
|
+
| Malta | MT | 31 |
|
|
165
|
+
| Mauritania | MR | 27 |
|
|
166
|
+
| Mauritius | MU | 30 |
|
|
167
|
+
| Moldova | MD | 24 |
|
|
168
|
+
| Monaco | MC | 27 |
|
|
169
|
+
| Mongolia | MN | 20 |
|
|
170
|
+
| Montenegro | ME | 22 |
|
|
171
|
+
| Morocco | MA | 28 |
|
|
172
|
+
| Mozambique | MZ | 25 |
|
|
173
|
+
| Netherlands | NL | 18 |
|
|
174
|
+
| Nicaragua | NI | 32 |
|
|
175
|
+
| Niger | NE | 28 |
|
|
176
|
+
| North Macedonia | MK | 19 |
|
|
177
|
+
| Norway | NO | 15 |
|
|
178
|
+
| Pakistan | PK | 24 |
|
|
179
|
+
| Palestine | PS | 29 |
|
|
180
|
+
| Poland | PL | 28 |
|
|
181
|
+
| Portugal | PT | 25 |
|
|
182
|
+
| Qatar | QA | 29 |
|
|
183
|
+
| Romania | RO | 24 |
|
|
184
|
+
| Russia | RU | 33 |
|
|
185
|
+
| Saint Lucia | LC | 32 |
|
|
186
|
+
| San Marino | SM | 27 |
|
|
187
|
+
| Sao Tome and Principe | ST | 25 |
|
|
188
|
+
| Saudi Arabia | SA | 24 |
|
|
189
|
+
| Senegal | SN | 28 |
|
|
190
|
+
| Serbia | RS | 22 |
|
|
191
|
+
| Seychelles | SC | 31 |
|
|
192
|
+
| Slovak Republic | SK | 24 |
|
|
193
|
+
| Slovenia | SI | 19 |
|
|
194
|
+
| Spain | ES | 24 |
|
|
195
|
+
| Sudan | SD | 18 |
|
|
196
|
+
| Sweden | SE | 24 |
|
|
197
|
+
| Switzerland | CH | 21 |
|
|
198
|
+
| Timor-Leste | TL | 23 |
|
|
199
|
+
| Togo | TG | 28 |
|
|
200
|
+
| Tunisia | TN | 24 |
|
|
201
|
+
| Turkey | TR | 26 |
|
|
202
|
+
| Ukraine | UA | 29 |
|
|
203
|
+
| United Arab Emirates | AE | 23 |
|
|
204
|
+
| United Kingdom | GB | 22 |
|
|
205
|
+
| Virgin Islands, British | VG | 24 |
|
|
206
|
+
|
|
207
|
+
# Development
|
|
208
|
+
|
|
209
|
+
## Install dependencies
|
|
210
|
+
|
|
211
|
+
```bash
|
|
212
|
+
npm i
|
|
213
|
+
```
|
|
214
|
+
|
|
215
|
+
## Test
|
|
216
|
+
|
|
217
|
+
```bash
|
|
218
|
+
npm run test
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
## Build
|
|
222
|
+
|
|
223
|
+
```bash
|
|
224
|
+
npx tsc
|
|
225
|
+
```
|
|
226
|
+
|
|
227
|
+
# v 1.1.5
|
|
228
|
+
|
|
229
|
+
Added additional pattern validation
|
|
230
|
+
Added more tests to improve test coverage
|
|
231
|
+
Added support for new countries: Algeria, Angola, Benin, Burkina Faso, Burundi, Cameroon, Cape Verde, Central African Republic, Chad, Comoros, Congo, Equatorial Guinea, Gabon, Guinea-Bissau, Honduras, Iran, Ivory Coast, Madagascar, Mali, Mongolia, Morocco, Mozambique, Nicaragua, Niger, Russia, Senegal, Togo
|
|
232
|
+
|
|
233
|
+
# v 1.1.4
|
|
234
|
+
|
|
235
|
+
Avoid Angular warnings for old CommonJS module usage (see https://angular.io/guide/build#configuring-commonjs-dependencies)
|
|
236
|
+
|
|
237
|
+
Replaced mocha and chai with JEST for tests
|
|
238
|
+
|
|
239
|
+
# v 1.1.3
|
|
240
|
+
|
|
241
|
+
Added support for new countries: Vatican, Libya, Sao Tome and Principe, Sudan
|
|
242
|
+
Updated length for LC Saint Lucia from 30 to 32
|
|
243
|
+
|
|
244
|
+
Added Tests
|
|
245
|
+
Added Mocha and Chai for testing
|
|
246
|
+
|
|
247
|
+
# v 1.1.2
|
|
248
|
+
|
|
249
|
+
Updated length for CR to 22 - @freddy36
|
|
250
|
+
|
|
251
|
+
## Read more
|
|
252
|
+
|
|
253
|
+
[IBAN Examples](https://www.iban.com/structure)
|