@abitechdev/openchasqui-data-es-pe 0.1.0 → 0.1.1
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 +52 -7
- package/package.json +12 -1
package/README.md
CHANGED
|
@@ -1,12 +1,57 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<a href="https://github.com/abitech-dev/abitech-openchasqui-cli#readme"><img alt="OpenChasqui" src="https://raw.githubusercontent.com/abitech-dev/abitech-openchasqui-cli/main/.github/assets/logo-light.svg" width="320"></a>
|
|
3
|
+
</p>
|
|
4
|
+
|
|
1
5
|
# @abitechdev/openchasqui-data-es-pe
|
|
2
6
|
|
|
3
|
-
|
|
7
|
+
[](https://www.npmjs.com/package/@abitechdev/openchasqui-data-es-pe)
|
|
8
|
+
[](https://github.com/abitech-dev/abitech-openchasqui-cli/actions/workflows/ci.yml)
|
|
9
|
+
[](https://github.com/abitech-dev/abitech-openchasqui-cli/blob/main/LICENSE)
|
|
10
|
+
|
|
11
|
+
Datos de prueba peruanos, sintéticos y deterministas: nombres como los devuelve RENIEC, DNI, RUC con dígito verificador SUNAT, celulares y ubigeo. Sirve también fuera de OpenChasqui, en cualquier prueba.
|
|
12
|
+
|
|
13
|
+
## Instalación
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
npm i @abitechdev/openchasqui-data-es-pe
|
|
17
|
+
pnpm add @abitechdev/openchasqui-data-es-pe
|
|
18
|
+
yarn add @abitechdev/openchasqui-data-es-pe
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
Requiere Node.js 22 o superior.
|
|
22
|
+
|
|
23
|
+
## Uso
|
|
24
|
+
|
|
25
|
+
```ts
|
|
26
|
+
import {
|
|
27
|
+
createRandom,
|
|
28
|
+
dni,
|
|
29
|
+
isValidRuc,
|
|
30
|
+
person,
|
|
31
|
+
ruc,
|
|
32
|
+
ubigeo,
|
|
33
|
+
} from "@abitechdev/openchasqui-data-es-pe";
|
|
34
|
+
|
|
35
|
+
const random = createRandom("mi-prueba"); // la misma semilla da los mismos datos
|
|
36
|
+
|
|
37
|
+
const cliente = person(random);
|
|
38
|
+
cliente.givenNames; // "Jorge Manuel"
|
|
39
|
+
cliente.surnames; // "Díaz Mendoza"
|
|
40
|
+
cliente.email; // "jorge.diaz@example.com"
|
|
41
|
+
|
|
42
|
+
dni(random); // "91836612"
|
|
43
|
+
ruc(random, "company"); // "20288603341"
|
|
44
|
+
ubigeo(random); // { code: "010101", department: "Amazonas", district: "Chachapoyas" }
|
|
45
|
+
isValidRuc("20131312955"); // true
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Los correos usan dominios reservados y ningún dato corresponde a una persona
|
|
49
|
+
real.
|
|
50
|
+
|
|
51
|
+
## Documentación
|
|
4
52
|
|
|
5
|
-
|
|
6
|
-
([en español](https://github.com/abitech-dev/abitech-openchasqui-cli#readme)), which generates API collections from
|
|
7
|
-
OpenAPI. Most projects only need the command line,
|
|
8
|
-
[`@abitechdev/openchasqui`](https://www.npmjs.com/package/@abitechdev/openchasqui).
|
|
53
|
+
[Español](https://github.com/abitech-dev/abitech-openchasqui-cli#readme) · [English](https://github.com/abitech-dev/abitech-openchasqui-cli/blob/main/README.en.md)
|
|
9
54
|
|
|
10
|
-
##
|
|
55
|
+
## Licencia
|
|
11
56
|
|
|
12
|
-
Apache-2.0
|
|
57
|
+
[Apache-2.0](https://github.com/abitech-dev/abitech-openchasqui-cli/blob/main/LICENSE). Parte de [OpenChasqui](https://github.com/abitech-dev/abitech-openchasqui-cli).
|
package/package.json
CHANGED
|
@@ -1,7 +1,18 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@abitechdev/openchasqui-data-es-pe",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "Deterministic synthetic Peruvian test data: names, DNI, RUC with SUNAT check digit, phones and ubigeo.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"peru",
|
|
7
|
+
"test-data",
|
|
8
|
+
"fake-data",
|
|
9
|
+
"dni",
|
|
10
|
+
"ruc",
|
|
11
|
+
"sunat",
|
|
12
|
+
"reniec",
|
|
13
|
+
"ubigeo",
|
|
14
|
+
"openchasqui"
|
|
15
|
+
],
|
|
5
16
|
"license": "Apache-2.0",
|
|
6
17
|
"type": "module",
|
|
7
18
|
"exports": {
|