struct-fakerator 2.4.4 → 2.4.6
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/package.json +19 -1
- package/src/utils/airline.ts +4 -9
- package/src/utils/animal.ts +16 -33
- package/src/utils/color.ts +18 -26
- package/src/utils/commerce.ts +15 -23
- package/src/utils/company.ts +14 -27
- package/src/utils/database.ts +8 -13
- package/src/utils/datatype.ts +2 -4
- package/src/utils/datetime.ts +12 -24
- package/src/utils/finance.ts +26 -54
- package/src/utils/food.ts +10 -24
- package/src/utils/git.ts +6 -14
- package/src/utils/hacker.ts +7 -15
- package/src/utils/image.ts +9 -22
- package/src/utils/index.ts +2 -0
- package/src/utils/internet.ts +21 -52
- package/src/utils/location.ts +25 -45
- package/src/utils/lorem.ts +10 -22
- package/src/utils/music.ts +5 -9
- package/src/utils/number.ts +7 -13
- package/src/utils/person.ts +16 -38
- package/src/utils/phone.ts +3 -5
- package/src/utils/science.ts +3 -6
- package/src/utils/string.ts +11 -24
- package/src/utils/system.ts +15 -34
- package/src/utils/utils.ts +8 -0
- package/src/utils/vehicle.ts +10 -20
- package/src/utils/word.ts +10 -23
- package/dist/airline-BUwgrfsj.d.ts +0 -26
- package/dist/airline-C0ManYED.d.mts +0 -26
- package/dist/animal-arG64NM6.d.mts +0 -53
- package/dist/animal-erAZXs_d.d.ts +0 -53
- package/dist/chunk-2R3Q64AD.mjs +0 -28
- package/dist/chunk-3HQMGDUF.js +0 -98
- package/dist/chunk-4UGSTE5Q.js +0 -1968
- package/dist/chunk-5U5KT6H4.js +0 -61
- package/dist/chunk-7GE2A5VT.mjs +0 -43
- package/dist/chunk-7R4M2AAS.js +0 -25
- package/dist/chunk-7YNCYSJY.js +0 -19
- package/dist/chunk-A5HM6XTD.js +0 -76
- package/dist/chunk-AONYMB6O.mjs +0 -40
- package/dist/chunk-ARUJ7L4V.mjs +0 -64
- package/dist/chunk-BB5LVHI7.mjs +0 -46
- package/dist/chunk-BELV2S6H.js +0 -46
- package/dist/chunk-BS7IEV74.mjs +0 -1968
- package/dist/chunk-BXJJGEM5.js +0 -22
- package/dist/chunk-CFX43E3I.mjs +0 -22
- package/dist/chunk-D7PC2EQM.mjs +0 -73
- package/dist/chunk-DF3HCW6W.js +0 -43
- package/dist/chunk-DVBKP7FB.mjs +0 -31
- package/dist/chunk-EDATUWC4.js +0 -40
- package/dist/chunk-FLNVEEY2.mjs +0 -34
- package/dist/chunk-GE7QO474.js +0 -64
- package/dist/chunk-H4XUR4CP.mjs +0 -34
- package/dist/chunk-HADENNJW.js +0 -22
- package/dist/chunk-HHL3SY7A.js +0 -34
- package/dist/chunk-HOVGSNA4.js +0 -73
- package/dist/chunk-J266ZY25.mjs +0 -22
- package/dist/chunk-J3IXKUJK.js +0 -61
- package/dist/chunk-J5ZX7PK3.js +0 -34
- package/dist/chunk-L7PFM742.mjs +0 -49
- package/dist/chunk-LBQLRQOQ.js +0 -28
- package/dist/chunk-LJKI4ZZ5.mjs +0 -43
- package/dist/chunk-M2J3MAM7.mjs +0 -52
- package/dist/chunk-NEE5QKPY.mjs +0 -40
- package/dist/chunk-OLSCXZ3D.mjs +0 -98
- package/dist/chunk-P65FYBLE.mjs +0 -61
- package/dist/chunk-PVPH6A5C.mjs +0 -43
- package/dist/chunk-RKTNWUZK.js +0 -43
- package/dist/chunk-S73SWVKV.js +0 -31
- package/dist/chunk-SYSS7JTS.js +0 -49
- package/dist/chunk-T5JPOARU.js +0 -40
- package/dist/chunk-TX7HRLKE.mjs +0 -19
- package/dist/chunk-USSK73G6.js +0 -43
- package/dist/chunk-VCWW76K4.mjs +0 -61
- package/dist/chunk-WJ5EC6UN.js +0 -49
- package/dist/chunk-X5TOZB77.mjs +0 -43
- package/dist/chunk-XG6RUZSI.mjs +0 -16
- package/dist/chunk-XL5V4E3Z.js +0 -16
- package/dist/chunk-XPZ47TRN.js +0 -52
- package/dist/chunk-YJWVP2PN.mjs +0 -31
- package/dist/chunk-YQWQUNOA.js +0 -31
- package/dist/chunk-YTTIRC5J.mjs +0 -49
- package/dist/chunk-YY2TF7WC.mjs +0 -25
- package/dist/chunk-ZPQWZLYI.js +0 -43
- package/dist/chunk-ZRQDW34U.mjs +0 -76
- package/dist/color-BmTZnKiW.d.mts +0 -61
- package/dist/color-WFinq_Y4.d.ts +0 -61
- package/dist/commerce-Ch71_dd2.d.ts +0 -40
- package/dist/commerce-IGFkOXjQ.d.mts +0 -40
- package/dist/common-CbuXAeQ-.d.mts +0 -11
- package/dist/common-Kp8LaAzK.d.ts +0 -11
- package/dist/company---O1IwYo.d.ts +0 -35
- package/dist/company-D7Cc_hsx.d.mts +0 -35
- package/dist/database-B8Wr1oXH.d.mts +0 -23
- package/dist/database-Dnsy3cQb.d.ts +0 -23
- package/dist/datatype-CAu_sc1g.d.ts +0 -13
- package/dist/datatype-gjFHrdMj.d.mts +0 -13
- package/dist/datetime-BDgsnqq_.d.mts +0 -78
- package/dist/datetime-BkidbR1O.d.ts +0 -78
- package/dist/finance-BZEmlfNQ.d.mts +0 -90
- package/dist/finance-Cn3DFbX4.d.ts +0 -90
- package/dist/food-CfxZX81O.d.mts +0 -35
- package/dist/food-tr11e_Qp.d.ts +0 -35
- package/dist/git-DoCI9ZYT.d.ts +0 -31
- package/dist/git-Feo1ntKa.d.mts +0 -31
- package/dist/hacker-X3zBTMoE.d.ts +0 -26
- package/dist/hacker-mGVIO_wL.d.mts +0 -26
- package/dist/image-BeZbZlyo.d.ts +0 -56
- package/dist/image-govZ7HjA.d.mts +0 -56
- package/dist/index.d.mts +0 -57
- package/dist/index.d.ts +0 -57
- package/dist/index.js +0 -162
- package/dist/index.mjs +0 -162
- package/dist/internet-CJEETk0v.d.mts +0 -101
- package/dist/internet-jHHnqVJG.d.ts +0 -101
- package/dist/location-CTA_Bq7w.d.mts +0 -80
- package/dist/location-CsVekxIU.d.ts +0 -80
- package/dist/lorem-BE4n3dVs.d.mts +0 -62
- package/dist/lorem-Btv0fltY.d.ts +0 -62
- package/dist/music-CQ3lnDvg.d.mts +0 -20
- package/dist/music-D3zj5REe.d.ts +0 -20
- package/dist/number-Bj9ydAOH.d.ts +0 -47
- package/dist/number-D9Wn_qjS.d.mts +0 -47
- package/dist/person-LLleVozS.d.ts +0 -58
- package/dist/person-OKRyYmeX.d.mts +0 -58
- package/dist/phone-Bc8UXPF3.d.ts +0 -16
- package/dist/phone-QbHXAqVF.d.mts +0 -16
- package/dist/science-BgXAZ3YR.d.ts +0 -15
- package/dist/science-CSN41yUZ.d.mts +0 -15
- package/dist/string-9w976kVk.d.mts +0 -87
- package/dist/string-Cm9TczI6.d.ts +0 -87
- package/dist/system-DOyHjHxs.d.mts +0 -55
- package/dist/system-DipW6DYb.d.ts +0 -55
- package/dist/type-C8Ny1fB6.d.mts +0 -33
- package/dist/type-C8Ny1fB6.d.ts +0 -33
- package/dist/utils/airline.d.mts +0 -3
- package/dist/utils/airline.d.ts +0 -3
- package/dist/utils/airline.js +0 -12
- package/dist/utils/airline.mjs +0 -12
- package/dist/utils/animal.d.mts +0 -2
- package/dist/utils/animal.d.ts +0 -2
- package/dist/utils/animal.js +0 -36
- package/dist/utils/animal.mjs +0 -36
- package/dist/utils/color.d.mts +0 -3
- package/dist/utils/color.d.ts +0 -3
- package/dist/utils/color.js +0 -28
- package/dist/utils/color.mjs +0 -28
- package/dist/utils/commerce.d.mts +0 -2
- package/dist/utils/commerce.d.ts +0 -2
- package/dist/utils/commerce.js +0 -22
- package/dist/utils/commerce.mjs +0 -22
- package/dist/utils/common.d.mts +0 -2
- package/dist/utils/common.d.ts +0 -2
- package/dist/utils/common.js +0 -7
- package/dist/utils/common.mjs +0 -7
- package/dist/utils/company.d.mts +0 -2
- package/dist/utils/company.d.ts +0 -2
- package/dist/utils/company.js +0 -24
- package/dist/utils/company.mjs +0 -24
- package/dist/utils/database.d.mts +0 -2
- package/dist/utils/database.d.ts +0 -2
- package/dist/utils/database.js +0 -16
- package/dist/utils/database.mjs +0 -16
- package/dist/utils/datatype.d.mts +0 -2
- package/dist/utils/datatype.d.ts +0 -2
- package/dist/utils/datatype.js +0 -8
- package/dist/utils/datatype.mjs +0 -8
- package/dist/utils/datetime.d.mts +0 -2
- package/dist/utils/datetime.d.ts +0 -2
- package/dist/utils/datetime.js +0 -28
- package/dist/utils/datetime.mjs +0 -28
- package/dist/utils/finance.d.mts +0 -3
- package/dist/utils/finance.d.ts +0 -3
- package/dist/utils/finance.js +0 -44
- package/dist/utils/finance.mjs +0 -44
- package/dist/utils/food.d.mts +0 -2
- package/dist/utils/food.d.ts +0 -2
- package/dist/utils/food.js +0 -24
- package/dist/utils/food.mjs +0 -24
- package/dist/utils/git.d.mts +0 -2
- package/dist/utils/git.d.ts +0 -2
- package/dist/utils/git.js +0 -16
- package/dist/utils/git.mjs +0 -16
- package/dist/utils/hacker.d.mts +0 -2
- package/dist/utils/hacker.d.ts +0 -2
- package/dist/utils/hacker.js +0 -18
- package/dist/utils/hacker.mjs +0 -18
- package/dist/utils/image.d.mts +0 -2
- package/dist/utils/image.d.ts +0 -2
- package/dist/utils/image.js +0 -22
- package/dist/utils/image.mjs +0 -22
- package/dist/utils/index.d.mts +0 -27
- package/dist/utils/index.d.ts +0 -27
- package/dist/utils/index.js +0 -104
- package/dist/utils/index.mjs +0 -104
- package/dist/utils/internet.d.mts +0 -2
- package/dist/utils/internet.d.ts +0 -2
- package/dist/utils/internet.js +0 -46
- package/dist/utils/internet.mjs +0 -46
- package/dist/utils/location.d.mts +0 -2
- package/dist/utils/location.d.ts +0 -2
- package/dist/utils/location.js +0 -38
- package/dist/utils/location.mjs +0 -38
- package/dist/utils/lorem.d.mts +0 -2
- package/dist/utils/lorem.d.ts +0 -2
- package/dist/utils/lorem.js +0 -24
- package/dist/utils/lorem.mjs +0 -24
- package/dist/utils/music.d.mts +0 -2
- package/dist/utils/music.d.ts +0 -2
- package/dist/utils/music.js +0 -14
- package/dist/utils/music.mjs +0 -14
- package/dist/utils/number.d.mts +0 -2
- package/dist/utils/number.d.ts +0 -2
- package/dist/utils/number.js +0 -18
- package/dist/utils/number.mjs +0 -18
- package/dist/utils/person.d.mts +0 -3
- package/dist/utils/person.d.ts +0 -3
- package/dist/utils/person.js +0 -36
- package/dist/utils/person.mjs +0 -36
- package/dist/utils/phone.d.mts +0 -2
- package/dist/utils/phone.d.ts +0 -2
- package/dist/utils/phone.js +0 -10
- package/dist/utils/phone.mjs +0 -10
- package/dist/utils/science.d.mts +0 -3
- package/dist/utils/science.d.ts +0 -3
- package/dist/utils/science.js +0 -10
- package/dist/utils/science.mjs +0 -10
- package/dist/utils/string.d.mts +0 -2
- package/dist/utils/string.d.ts +0 -2
- package/dist/utils/string.js +0 -26
- package/dist/utils/string.mjs +0 -26
- package/dist/utils/system.d.mts +0 -2
- package/dist/utils/system.d.ts +0 -2
- package/dist/utils/system.js +0 -30
- package/dist/utils/system.mjs +0 -30
- package/dist/utils/vehicle.d.mts +0 -2
- package/dist/utils/vehicle.d.ts +0 -2
- package/dist/utils/vehicle.js +0 -24
- package/dist/utils/vehicle.mjs +0 -24
- package/dist/utils/word.d.mts +0 -75
- package/dist/utils/word.d.ts +0 -75
- package/dist/utils/word.js +0 -28
- package/dist/utils/word.mjs +0 -28
- package/dist/vehicle-DmBDda98.d.mts +0 -35
- package/dist/vehicle-rnBz1Za2.d.ts +0 -35
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "struct-fakerator",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.6",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -24,6 +24,24 @@
|
|
|
24
24
|
"default": "./dist/index.mjs"
|
|
25
25
|
}
|
|
26
26
|
},
|
|
27
|
+
"./utils": {
|
|
28
|
+
"default": {
|
|
29
|
+
"types": "./dist/utils/index.d.ts",
|
|
30
|
+
"default": "./dist/utils/index.mjs"
|
|
31
|
+
},
|
|
32
|
+
"require": {
|
|
33
|
+
"types": "./dist/utils/index.d.ts",
|
|
34
|
+
"default": "./dist/utils/index.js"
|
|
35
|
+
},
|
|
36
|
+
"import": {
|
|
37
|
+
"types": "./dist/utils/index.d.ts",
|
|
38
|
+
"default": "./dist/utils/index.mjs"
|
|
39
|
+
},
|
|
40
|
+
"module": {
|
|
41
|
+
"types": "./dist/utils/index.d.ts",
|
|
42
|
+
"default": "./dist/utils/index.mjs"
|
|
43
|
+
}
|
|
44
|
+
},
|
|
27
45
|
"./utils/*": {
|
|
28
46
|
"default": {
|
|
29
47
|
"types": "./dist/utils/*.d.ts",
|
package/src/utils/airline.ts
CHANGED
|
@@ -1,16 +1,11 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Airline [aircraftType](https://fakerjs.dev/api/airline.html#aircraftType) */
|
|
5
|
-
export const aircraftType = (
|
|
6
|
-
...options: Parameters<typeof faker.airline.aircraftType>
|
|
7
|
-
) => createValueConfig(() => faker.airline.aircraftType(...options));
|
|
5
|
+
export const aircraftType = makeValueConfigFn(faker.airline.aircraftType);
|
|
8
6
|
|
|
9
7
|
/** Airline [flightNumber](https://fakerjs.dev/api/airline.html#flightNumber) */
|
|
10
|
-
export const flightNumber = (
|
|
11
|
-
...options: Parameters<typeof faker.airline.flightNumber>
|
|
12
|
-
) => createValueConfig(() => faker.airline.flightNumber(...options));
|
|
8
|
+
export const flightNumber = makeValueConfigFn(faker.airline.flightNumber);
|
|
13
9
|
|
|
14
10
|
/** Airline [seat](https://fakerjs.dev/api/airline.html#seat) */
|
|
15
|
-
export const seat = (
|
|
16
|
-
createValueConfig(() => faker.airline.seat(...options));
|
|
11
|
+
export const seat = makeValueConfigFn(faker.airline.seat);
|
package/src/utils/animal.ts
CHANGED
|
@@ -1,64 +1,47 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Animal [bear](https://fakerjs.dev/api/animal.html#bear) */
|
|
5
|
-
export const bear = (
|
|
6
|
-
createValueConfig(() => faker.animal.bear(...options));
|
|
5
|
+
export const bear = makeValueConfigFn(faker.animal.bear);
|
|
7
6
|
|
|
8
7
|
/** Animal [bird](https://fakerjs.dev/api/animal.html#bird) */
|
|
9
|
-
export const bird = (
|
|
10
|
-
createValueConfig(() => faker.animal.bird(...options));
|
|
8
|
+
export const bird = makeValueConfigFn(faker.animal.bird);
|
|
11
9
|
|
|
12
10
|
/** Animal [cat](https://fakerjs.dev/api/animal.html#cat) */
|
|
13
|
-
export const cat = (
|
|
14
|
-
createValueConfig(() => faker.animal.cat(...options));
|
|
11
|
+
export const cat = makeValueConfigFn(faker.animal.cat);
|
|
15
12
|
|
|
16
13
|
/** Animal [cetacean](https://fakerjs.dev/api/animal.html#cetacean) */
|
|
17
|
-
export const cetacean = (
|
|
18
|
-
...options: Parameters<typeof faker.animal.cetacean>
|
|
19
|
-
) => createValueConfig(() => faker.animal.cetacean(...options));
|
|
14
|
+
export const cetacean = makeValueConfigFn(faker.animal.cetacean);
|
|
20
15
|
|
|
21
16
|
/** Animal [cow](https://fakerjs.dev/api/animal.html#cow) */
|
|
22
|
-
export const cow = (
|
|
23
|
-
createValueConfig(() => faker.animal.cow(...options));
|
|
17
|
+
export const cow = makeValueConfigFn(faker.animal.cow);
|
|
24
18
|
|
|
25
19
|
/** Animal [crocodilia](https://fakerjs.dev/api/animal.html#crocodilia) */
|
|
26
|
-
export const crocodilia = (
|
|
27
|
-
...options: Parameters<typeof faker.animal.crocodilia>
|
|
28
|
-
) => createValueConfig(() => faker.animal.crocodilia(...options));
|
|
20
|
+
export const crocodilia = makeValueConfigFn(faker.animal.crocodilia);
|
|
29
21
|
|
|
30
22
|
/** Animal [dog](https://fakerjs.dev/api/animal.html#dog) */
|
|
31
|
-
export const dog = (
|
|
32
|
-
createValueConfig(() => faker.animal.dog(...options));
|
|
23
|
+
export const dog = makeValueConfigFn(faker.animal.dog);
|
|
33
24
|
|
|
34
25
|
/** Animal [fish](https://fakerjs.dev/api/animal.html#fish) */
|
|
35
|
-
export const fish = (
|
|
36
|
-
createValueConfig(() => faker.animal.fish(...options));
|
|
26
|
+
export const fish = makeValueConfigFn(faker.animal.fish);
|
|
37
27
|
|
|
38
28
|
/** Animal [horse](https://fakerjs.dev/api/animal.html#horse) */
|
|
39
|
-
export const horse = (
|
|
40
|
-
createValueConfig(() => faker.animal.horse(...options));
|
|
29
|
+
export const horse = makeValueConfigFn(faker.animal.horse);
|
|
41
30
|
|
|
42
31
|
/** Animal [insect](https://fakerjs.dev/api/animal.html#insect) */
|
|
43
|
-
export const insect = (
|
|
44
|
-
createValueConfig(() => faker.animal.insect(...options));
|
|
32
|
+
export const insect = makeValueConfigFn(faker.animal.insect);
|
|
45
33
|
|
|
46
34
|
/** Animal [lion](https://fakerjs.dev/api/animal.html#lion) */
|
|
47
|
-
export const lion = (
|
|
48
|
-
createValueConfig(() => faker.animal.lion(...options));
|
|
35
|
+
export const lion = makeValueConfigFn(faker.animal.lion);
|
|
49
36
|
|
|
50
37
|
/** Animal [rabbit](https://fakerjs.dev/api/animal.html#rabbit) */
|
|
51
|
-
export const rabbit = (
|
|
52
|
-
createValueConfig(() => faker.animal.rabbit(...options));
|
|
38
|
+
export const rabbit = makeValueConfigFn(faker.animal.rabbit);
|
|
53
39
|
|
|
54
40
|
/** Animal [rodent](https://fakerjs.dev/api/animal.html#rodent) */
|
|
55
|
-
export const rodent = (
|
|
56
|
-
createValueConfig(() => faker.animal.rodent(...options));
|
|
41
|
+
export const rodent = makeValueConfigFn(faker.animal.rodent);
|
|
57
42
|
|
|
58
43
|
/** Animal [snake](https://fakerjs.dev/api/animal.html#snake) */
|
|
59
|
-
export const snake = (
|
|
60
|
-
createValueConfig(() => faker.animal.snake(...options));
|
|
44
|
+
export const snake = makeValueConfigFn(faker.animal.snake);
|
|
61
45
|
|
|
62
46
|
/** Animal [type](https://fakerjs.dev/api/animal.html#type) */
|
|
63
|
-
export const type = (
|
|
64
|
-
createValueConfig(() => faker.animal.type(...options));
|
|
47
|
+
export const type = makeValueConfigFn(faker.animal.type);
|
package/src/utils/color.ts
CHANGED
|
@@ -1,49 +1,41 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Color [cmyk](https://fakerjs.dev/api/color.html#cmyk) */
|
|
5
|
-
export const cmyk = (
|
|
6
|
-
createValueConfig(() => faker.color.cmyk(...options));
|
|
5
|
+
export const cmyk = makeValueConfigFn(faker.color.cmyk);
|
|
7
6
|
|
|
8
7
|
/** Color [colorByCSSColorSpace](https://fakerjs.dev/api/color.html#colorByCSSColorSpace) */
|
|
9
|
-
export const colorByCSSColorSpace = (
|
|
10
|
-
|
|
11
|
-
)
|
|
8
|
+
export const colorByCSSColorSpace = makeValueConfigFn(
|
|
9
|
+
faker.color.colorByCSSColorSpace,
|
|
10
|
+
);
|
|
12
11
|
|
|
13
12
|
/** Color [cssSupportedFunction](https://fakerjs.dev/api/color.html#cssSupportedFunction) */
|
|
14
|
-
export const cssSupportedFunction = (
|
|
15
|
-
|
|
16
|
-
)
|
|
13
|
+
export const cssSupportedFunction = makeValueConfigFn(
|
|
14
|
+
faker.color.cssSupportedFunction,
|
|
15
|
+
);
|
|
17
16
|
|
|
18
17
|
/** Color [cssSupportedSpace](https://fakerjs.dev/api/color.html#cssSupportedSpace) */
|
|
19
|
-
export const cssSupportedSpace = (
|
|
20
|
-
|
|
21
|
-
)
|
|
18
|
+
export const cssSupportedSpace = makeValueConfigFn(
|
|
19
|
+
faker.color.cssSupportedSpace,
|
|
20
|
+
);
|
|
22
21
|
|
|
23
22
|
/** Color [hsl](https://fakerjs.dev/api/color.html#hsl) */
|
|
24
|
-
export const hsl = (
|
|
25
|
-
createValueConfig(() => faker.color.hsl(...options));
|
|
23
|
+
export const hsl = makeValueConfigFn(faker.color.hsl);
|
|
26
24
|
|
|
27
25
|
/** Color [human](https://fakerjs.dev/api/color.html#human) */
|
|
28
|
-
export const human = (
|
|
29
|
-
createValueConfig(() => faker.color.human(...options));
|
|
26
|
+
export const human = makeValueConfigFn(faker.color.human);
|
|
30
27
|
|
|
31
28
|
/** Color [hwb](https://fakerjs.dev/api/color.html#hwb) */
|
|
32
|
-
export const hwb = (
|
|
33
|
-
createValueConfig(() => faker.color.hwb(...options));
|
|
29
|
+
export const hwb = makeValueConfigFn(faker.color.hwb);
|
|
34
30
|
|
|
35
31
|
/** Color [lab](https://fakerjs.dev/api/color.html#lab) */
|
|
36
|
-
export const lab = (
|
|
37
|
-
createValueConfig(() => faker.color.lab(...options));
|
|
32
|
+
export const lab = makeValueConfigFn(faker.color.lab);
|
|
38
33
|
|
|
39
34
|
/** Color [lch](https://fakerjs.dev/api/color.html#lch) */
|
|
40
|
-
export const lch = (
|
|
41
|
-
createValueConfig(() => faker.color.lch(...options));
|
|
35
|
+
export const lch = makeValueConfigFn(faker.color.lch);
|
|
42
36
|
|
|
43
37
|
/** Color [rgb](https://fakerjs.dev/api/color.html#rgb) */
|
|
44
|
-
export const rgb = (
|
|
45
|
-
createValueConfig(() => faker.color.rgb(...options));
|
|
38
|
+
export const rgb = makeValueConfigFn(faker.color.rgb);
|
|
46
39
|
|
|
47
40
|
/** Color [space](https://fakerjs.dev/api/color.html#space) */
|
|
48
|
-
export const space = (
|
|
49
|
-
createValueConfig(() => faker.color.space(...options));
|
|
41
|
+
export const space = makeValueConfigFn(faker.color.space);
|
package/src/utils/commerce.ts
CHANGED
|
@@ -1,40 +1,32 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Commerce [department](https://fakerjs.dev/api/commerce.html#department) */
|
|
5
|
-
export const department = (
|
|
6
|
-
...options: Parameters<typeof faker.commerce.department>
|
|
7
|
-
) => createValueConfig(() => faker.commerce.department(...options));
|
|
5
|
+
export const department = makeValueConfigFn(faker.commerce.department);
|
|
8
6
|
|
|
9
7
|
/** Commerce [isbn](https://fakerjs.dev/api/commerce.html#isbn) */
|
|
10
|
-
export const isbn = (
|
|
11
|
-
createValueConfig(() => faker.commerce.isbn(...options));
|
|
8
|
+
export const isbn = makeValueConfigFn(faker.commerce.isbn);
|
|
12
9
|
|
|
13
10
|
/** Commerce [price](https://fakerjs.dev/api/commerce.html#price) */
|
|
14
|
-
export const price = (
|
|
15
|
-
createValueConfig(() => faker.commerce.price(...options));
|
|
11
|
+
export const price = makeValueConfigFn(faker.commerce.price);
|
|
16
12
|
|
|
17
13
|
/** Commerce [product](https://fakerjs.dev/api/commerce.html#product) */
|
|
18
|
-
export const product = (
|
|
19
|
-
...options: Parameters<typeof faker.commerce.product>
|
|
20
|
-
) => createValueConfig(() => faker.commerce.product(...options));
|
|
14
|
+
export const product = makeValueConfigFn(faker.commerce.product);
|
|
21
15
|
|
|
22
16
|
/** Commerce [productAdjective](https://fakerjs.dev/api/commerce.html#productAdjective) */
|
|
23
|
-
export const productAdjective = (
|
|
24
|
-
|
|
25
|
-
)
|
|
17
|
+
export const productAdjective = makeValueConfigFn(
|
|
18
|
+
faker.commerce.productAdjective,
|
|
19
|
+
);
|
|
26
20
|
|
|
27
21
|
/** Commerce [productDescription](https://fakerjs.dev/api/commerce.html#productDescription) */
|
|
28
|
-
export const productDescription = (
|
|
29
|
-
|
|
30
|
-
)
|
|
22
|
+
export const productDescription = makeValueConfigFn(
|
|
23
|
+
faker.commerce.productDescription,
|
|
24
|
+
);
|
|
31
25
|
|
|
32
26
|
/** Commerce [productMaterial](https://fakerjs.dev/api/commerce.html#productMaterial) */
|
|
33
|
-
export const productMaterial = (
|
|
34
|
-
|
|
35
|
-
)
|
|
27
|
+
export const productMaterial = makeValueConfigFn(
|
|
28
|
+
faker.commerce.productMaterial,
|
|
29
|
+
);
|
|
36
30
|
|
|
37
31
|
/** Commerce [productName](https://fakerjs.dev/api/commerce.html#productName) */
|
|
38
|
-
export const productName = (
|
|
39
|
-
...options: Parameters<typeof faker.commerce.productName>
|
|
40
|
-
) => createValueConfig(() => faker.commerce.productName(...options));
|
|
32
|
+
export const productName = makeValueConfigFn(faker.commerce.productName);
|
package/src/utils/company.ts
CHANGED
|
@@ -1,46 +1,33 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Company [buzzAdjective](https://fakerjs.dev/api/company.html#buzzAdjective) */
|
|
5
|
-
export const buzzAdjective = (
|
|
6
|
-
...options: Parameters<typeof faker.company.buzzAdjective>
|
|
7
|
-
) => createValueConfig(() => faker.company.buzzAdjective(...options));
|
|
5
|
+
export const buzzAdjective = makeValueConfigFn(faker.company.buzzAdjective);
|
|
8
6
|
|
|
9
7
|
/** Company [buzzNoun](https://fakerjs.dev/api/company.html#buzzNoun) */
|
|
10
|
-
export const buzzNoun = (
|
|
11
|
-
...options: Parameters<typeof faker.company.buzzNoun>
|
|
12
|
-
) => createValueConfig(() => faker.company.buzzNoun(...options));
|
|
8
|
+
export const buzzNoun = makeValueConfigFn(faker.company.buzzNoun);
|
|
13
9
|
|
|
14
10
|
/** Company [buzzPhrase](https://fakerjs.dev/api/company.html#buzzPhrase) */
|
|
15
|
-
export const buzzPhrase = (
|
|
16
|
-
...options: Parameters<typeof faker.company.buzzPhrase>
|
|
17
|
-
) => createValueConfig(() => faker.company.buzzPhrase(...options));
|
|
11
|
+
export const buzzPhrase = makeValueConfigFn(faker.company.buzzPhrase);
|
|
18
12
|
|
|
19
13
|
/** Company [buzzVerb](https://fakerjs.dev/api/company.html#buzzVerb) */
|
|
20
|
-
export const buzzVerb = (
|
|
21
|
-
...options: Parameters<typeof faker.company.buzzVerb>
|
|
22
|
-
) => createValueConfig(() => faker.company.buzzVerb(...options));
|
|
14
|
+
export const buzzVerb = makeValueConfigFn(faker.company.buzzVerb);
|
|
23
15
|
|
|
24
16
|
/** Company [catchPhrase](https://fakerjs.dev/api/company.html#catchPhrase) */
|
|
25
|
-
export const catchPhrase = (
|
|
26
|
-
...options: Parameters<typeof faker.company.catchPhrase>
|
|
27
|
-
) => createValueConfig(() => faker.company.catchPhrase(...options));
|
|
17
|
+
export const catchPhrase = makeValueConfigFn(faker.company.catchPhrase);
|
|
28
18
|
|
|
29
19
|
/** Company [catchPhraseAdjective](https://fakerjs.dev/api/company.html#catchPhraseAdjective) */
|
|
30
|
-
export const catchPhraseAdjective = (
|
|
31
|
-
|
|
32
|
-
)
|
|
20
|
+
export const catchPhraseAdjective = makeValueConfigFn(
|
|
21
|
+
faker.company.catchPhraseAdjective,
|
|
22
|
+
);
|
|
33
23
|
|
|
34
24
|
/** Company [catchPhraseDescriptor](https://fakerjs.dev/api/company.html#catchPhraseDescriptor) */
|
|
35
|
-
export const catchPhraseDescriptor = (
|
|
36
|
-
|
|
37
|
-
)
|
|
25
|
+
export const catchPhraseDescriptor = makeValueConfigFn(
|
|
26
|
+
faker.company.catchPhraseDescriptor,
|
|
27
|
+
);
|
|
38
28
|
|
|
39
29
|
/** Company [catchPhraseNoun](https://fakerjs.dev/api/company.html#catchPhraseNoun) */
|
|
40
|
-
export const catchPhraseNoun = (
|
|
41
|
-
...options: Parameters<typeof faker.company.catchPhraseNoun>
|
|
42
|
-
) => createValueConfig(() => faker.company.catchPhraseNoun(...options));
|
|
30
|
+
export const catchPhraseNoun = makeValueConfigFn(faker.company.catchPhraseNoun);
|
|
43
31
|
|
|
44
32
|
/** Company [name](https://fakerjs.dev/api/company.html#name) */
|
|
45
|
-
export const name = (
|
|
46
|
-
createValueConfig(() => faker.company.name(...options));
|
|
33
|
+
export const name = makeValueConfigFn(faker.company.name);
|
package/src/utils/database.ts
CHANGED
|
@@ -1,24 +1,19 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Database [collation](https://fakerjs.dev/api/database.html#collation) */
|
|
5
|
-
export const collation = (
|
|
6
|
-
...options: Parameters<typeof faker.database.collation>
|
|
7
|
-
) => createValueConfig(() => faker.database.collation(...options));
|
|
5
|
+
export const collation = makeValueConfigFn(faker.database.collation);
|
|
8
6
|
|
|
9
7
|
/** Database [column](https://fakerjs.dev/api/database.html#column) */
|
|
10
|
-
export const column = (
|
|
11
|
-
createValueConfig(() => faker.database.column(...options));
|
|
8
|
+
export const column = makeValueConfigFn(faker.database.column);
|
|
12
9
|
|
|
13
10
|
/** Database [engine](https://fakerjs.dev/api/database.html#engine) */
|
|
14
|
-
export const engine = (
|
|
15
|
-
createValueConfig(() => faker.database.engine(...options));
|
|
11
|
+
export const engine = makeValueConfigFn(faker.database.engine);
|
|
16
12
|
|
|
17
13
|
/** Database [mongodbObjectId](https://fakerjs.dev/api/database.html#mongodbObjectId) */
|
|
18
|
-
export const mongodbObjectId = (
|
|
19
|
-
|
|
20
|
-
)
|
|
14
|
+
export const mongodbObjectId = makeValueConfigFn(
|
|
15
|
+
faker.database.mongodbObjectId,
|
|
16
|
+
);
|
|
21
17
|
|
|
22
18
|
/** Database [type](https://fakerjs.dev/api/database.html#type) */
|
|
23
|
-
export const type = (
|
|
24
|
-
createValueConfig(() => faker.database.type(...options));
|
|
19
|
+
export const type = makeValueConfigFn(faker.database.type);
|
package/src/utils/datatype.ts
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Datatype [boolean](https://fakerjs.dev/api/datatype.html#boolean) */
|
|
5
|
-
export const boolean = (
|
|
6
|
-
...options: Parameters<typeof faker.datatype.boolean>
|
|
7
|
-
) => createValueConfig(() => faker.datatype.boolean(...options));
|
|
5
|
+
export const boolean = makeValueConfigFn(faker.datatype.boolean);
|
package/src/utils/datetime.ts
CHANGED
|
@@ -1,47 +1,35 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Datetime [anytime](https://fakerjs.dev/api/date.html#anytime) */
|
|
5
|
-
export const anytime = (
|
|
6
|
-
createValueConfig(() => faker.date.anytime(...options));
|
|
5
|
+
export const anytime = makeValueConfigFn(faker.date.anytime);
|
|
7
6
|
|
|
8
7
|
/** Datetime [between](https://fakerjs.dev/api/date.html#between) */
|
|
9
|
-
export const between = (
|
|
10
|
-
createValueConfig(() => faker.date.between(...options));
|
|
8
|
+
export const between = makeValueConfigFn(faker.date.between);
|
|
11
9
|
|
|
12
10
|
/** Datetime [betweens](https://fakerjs.dev/api/date.html#betweens) */
|
|
13
|
-
export const betweens = (
|
|
14
|
-
createValueConfig(() => faker.date.betweens(...options));
|
|
11
|
+
export const betweens = makeValueConfigFn(faker.date.betweens);
|
|
15
12
|
|
|
16
13
|
/** Datetime [birthdate](https://fakerjs.dev/api/date.html#birthdate) */
|
|
17
|
-
export const birthdate = (
|
|
18
|
-
...options: Parameters<typeof faker.date.birthdate>
|
|
19
|
-
) => createValueConfig(() => faker.date.birthdate(...options));
|
|
14
|
+
export const birthdate = makeValueConfigFn(faker.date.birthdate);
|
|
20
15
|
|
|
21
16
|
/** Datetime [future](https://fakerjs.dev/api/date.html#future) */
|
|
22
|
-
export const future = (
|
|
23
|
-
createValueConfig(() => faker.date.future(...options));
|
|
17
|
+
export const future = makeValueConfigFn(faker.date.future);
|
|
24
18
|
|
|
25
19
|
/** Datetime [month](https://fakerjs.dev/api/date.html#month) */
|
|
26
|
-
export const month = (
|
|
27
|
-
createValueConfig(() => faker.date.month(...options));
|
|
20
|
+
export const month = makeValueConfigFn(faker.date.month);
|
|
28
21
|
|
|
29
22
|
/** Datetime [past](https://fakerjs.dev/api/date.html#past) */
|
|
30
|
-
export const past = (
|
|
31
|
-
createValueConfig(() => faker.date.past(...options));
|
|
23
|
+
export const past = makeValueConfigFn(faker.date.past);
|
|
32
24
|
|
|
33
25
|
/** Datetime [recent](https://fakerjs.dev/api/date.html#recent) */
|
|
34
|
-
export const recent = (
|
|
35
|
-
createValueConfig(() => faker.date.recent(...options));
|
|
26
|
+
export const recent = makeValueConfigFn(faker.date.recent);
|
|
36
27
|
|
|
37
28
|
/** Datetime [soon](https://fakerjs.dev/api/date.html#soon) */
|
|
38
|
-
export const soon = (
|
|
39
|
-
createValueConfig(() => faker.date.soon(...options));
|
|
29
|
+
export const soon = makeValueConfigFn(faker.date.soon);
|
|
40
30
|
|
|
41
31
|
/** Datetime [timeZone](https://fakerjs.dev/api/date.html#timeZone) */
|
|
42
|
-
export const timeZone = (
|
|
43
|
-
createValueConfig(() => faker.date.timeZone(...options));
|
|
32
|
+
export const timeZone = makeValueConfigFn(faker.date.timeZone);
|
|
44
33
|
|
|
45
34
|
/** Datetime [weekday](https://fakerjs.dev/api/date.html#weekday) */
|
|
46
|
-
export const weekday = (
|
|
47
|
-
createValueConfig(() => faker.date.weekday(...options));
|
|
35
|
+
export const weekday = makeValueConfigFn(faker.date.weekday);
|
package/src/utils/finance.ts
CHANGED
|
@@ -1,93 +1,65 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Finance [accountName](https://fakerjs.dev/api/finance.html#accountName) */
|
|
5
|
-
export const accountName = (
|
|
6
|
-
...options: Parameters<typeof faker.finance.accountName>
|
|
7
|
-
) => createValueConfig(() => faker.finance.accountName(...options));
|
|
5
|
+
export const accountName = makeValueConfigFn(faker.finance.accountName);
|
|
8
6
|
|
|
9
7
|
/** Finance [accountNumber](https://fakerjs.dev/api/finance.html#accountNumber) */
|
|
10
|
-
export const accountNumber = (
|
|
11
|
-
...options: Parameters<typeof faker.finance.accountNumber>
|
|
12
|
-
) => createValueConfig(() => faker.finance.accountNumber(...options));
|
|
8
|
+
export const accountNumber = makeValueConfigFn(faker.finance.accountNumber);
|
|
13
9
|
|
|
14
10
|
/** Finance [amount](https://fakerjs.dev/api/finance.html#amount) */
|
|
15
|
-
export const amount = (
|
|
16
|
-
createValueConfig(() => faker.finance.amount(...options));
|
|
11
|
+
export const amount = makeValueConfigFn(faker.finance.amount);
|
|
17
12
|
|
|
18
13
|
/** Finance [bic](https://fakerjs.dev/api/finance.html#bic) */
|
|
19
|
-
export const bic = (
|
|
20
|
-
createValueConfig(() => faker.finance.bic(...options));
|
|
14
|
+
export const bic = makeValueConfigFn(faker.finance.bic);
|
|
21
15
|
|
|
22
16
|
/** Finance [bitcoinAddress](https://fakerjs.dev/api/finance.html#bitcoinAddress) */
|
|
23
|
-
export const bitcoinAddress = (
|
|
24
|
-
...options: Parameters<typeof faker.finance.bitcoinAddress>
|
|
25
|
-
) => createValueConfig(() => faker.finance.bitcoinAddress(...options));
|
|
17
|
+
export const bitcoinAddress = makeValueConfigFn(faker.finance.bitcoinAddress);
|
|
26
18
|
|
|
27
19
|
/** Finance [creditCardCVV](https://fakerjs.dev/api/finance.html#creditCardCVV) */
|
|
28
|
-
export const creditCardCVV = (
|
|
29
|
-
...options: Parameters<typeof faker.finance.creditCardCVV>
|
|
30
|
-
) => createValueConfig(() => faker.finance.creditCardCVV(...options));
|
|
20
|
+
export const creditCardCVV = makeValueConfigFn(faker.finance.creditCardCVV);
|
|
31
21
|
|
|
32
22
|
/** Finance [creditCardIssuer](https://fakerjs.dev/api/finance.html#creditCardIssuer) */
|
|
33
|
-
export const creditCardIssuer = (
|
|
34
|
-
|
|
35
|
-
)
|
|
23
|
+
export const creditCardIssuer = makeValueConfigFn(
|
|
24
|
+
faker.finance.creditCardIssuer,
|
|
25
|
+
);
|
|
36
26
|
|
|
37
27
|
/** Finance [creditCardNumber](https://fakerjs.dev/api/finance.html#creditCardNumber) */
|
|
38
|
-
export const creditCardNumber = (
|
|
39
|
-
|
|
40
|
-
)
|
|
28
|
+
export const creditCardNumber = makeValueConfigFn(
|
|
29
|
+
faker.finance.creditCardNumber,
|
|
30
|
+
);
|
|
41
31
|
|
|
42
32
|
/** Finance [currency](https://fakerjs.dev/api/finance.html#currency) */
|
|
43
|
-
export const currency = (
|
|
44
|
-
...options: Parameters<typeof faker.finance.currency>
|
|
45
|
-
) => createValueConfig(() => faker.finance.currency(...options));
|
|
33
|
+
export const currency = makeValueConfigFn(faker.finance.currency);
|
|
46
34
|
|
|
47
35
|
/** Finance [currencyCode](https://fakerjs.dev/api/finance.html#currencyCode) */
|
|
48
|
-
export const currencyCode = (
|
|
49
|
-
...options: Parameters<typeof faker.finance.currencyCode>
|
|
50
|
-
) => createValueConfig(() => faker.finance.currencyCode(...options));
|
|
36
|
+
export const currencyCode = makeValueConfigFn(faker.finance.currencyCode);
|
|
51
37
|
|
|
52
38
|
/** Finance [currencySymbol](https://fakerjs.dev/api/finance.html#currencySymbol) */
|
|
53
|
-
export const currencySymbol = (
|
|
54
|
-
...options: Parameters<typeof faker.finance.currencySymbol>
|
|
55
|
-
) => createValueConfig(() => faker.finance.currencySymbol(...options));
|
|
39
|
+
export const currencySymbol = makeValueConfigFn(faker.finance.currencySymbol);
|
|
56
40
|
|
|
57
41
|
/** Finance [ethereumAddress](https://fakerjs.dev/api/finance.html#ethereumAddress) */
|
|
58
|
-
export const ethereumAddress = (
|
|
59
|
-
...options: Parameters<typeof faker.finance.ethereumAddress>
|
|
60
|
-
) => createValueConfig(() => faker.finance.ethereumAddress(...options));
|
|
42
|
+
export const ethereumAddress = makeValueConfigFn(faker.finance.ethereumAddress);
|
|
61
43
|
|
|
62
44
|
/** Finance [iban](https://fakerjs.dev/api/finance.html#iban) */
|
|
63
|
-
export const iban = (
|
|
64
|
-
createValueConfig(() => faker.finance.iban(...options));
|
|
45
|
+
export const iban = makeValueConfigFn(faker.finance.iban);
|
|
65
46
|
|
|
66
47
|
/** Finance [litecoinAddress](https://fakerjs.dev/api/finance.html#litecoinAddress) */
|
|
67
|
-
export const litecoinAddress = (
|
|
68
|
-
...options: Parameters<typeof faker.finance.litecoinAddress>
|
|
69
|
-
) => createValueConfig(() => faker.finance.litecoinAddress(...options));
|
|
48
|
+
export const litecoinAddress = makeValueConfigFn(faker.finance.litecoinAddress);
|
|
70
49
|
|
|
71
50
|
/** Finance [maskedNumber](https://fakerjs.dev/api/finance.html#maskedNumber) */
|
|
72
|
-
export const maskedNumber = (
|
|
73
|
-
...options: Parameters<typeof faker.finance.maskedNumber>
|
|
74
|
-
) => createValueConfig(() => faker.finance.maskedNumber(...options));
|
|
51
|
+
export const maskedNumber = makeValueConfigFn(faker.finance.maskedNumber);
|
|
75
52
|
|
|
76
53
|
/** Finance [pin](https://fakerjs.dev/api/finance.html#pin) */
|
|
77
|
-
export const pin = (
|
|
78
|
-
createValueConfig(() => faker.finance.pin(...options));
|
|
54
|
+
export const pin = makeValueConfigFn(faker.finance.pin);
|
|
79
55
|
|
|
80
56
|
/** Finance [routingNumber](https://fakerjs.dev/api/finance.html#routingNumber) */
|
|
81
|
-
export const routingNumber = (
|
|
82
|
-
...options: Parameters<typeof faker.finance.routingNumber>
|
|
83
|
-
) => createValueConfig(() => faker.finance.routingNumber(...options));
|
|
57
|
+
export const routingNumber = makeValueConfigFn(faker.finance.routingNumber);
|
|
84
58
|
|
|
85
59
|
/** Finance [transactionDescription](https://fakerjs.dev/api/finance.html#transactionDescription) */
|
|
86
|
-
export const transactionDescription = (
|
|
87
|
-
|
|
88
|
-
)
|
|
60
|
+
export const transactionDescription = makeValueConfigFn(
|
|
61
|
+
faker.finance.transactionDescription,
|
|
62
|
+
);
|
|
89
63
|
|
|
90
64
|
/** Finance [transactionType](https://fakerjs.dev/api/finance.html#transactionType) */
|
|
91
|
-
export const transactionType = (
|
|
92
|
-
...options: Parameters<typeof faker.finance.transactionType>
|
|
93
|
-
) => createValueConfig(() => faker.finance.transactionType(...options));
|
|
65
|
+
export const transactionType = makeValueConfigFn(faker.finance.transactionType);
|
package/src/utils/food.ts
CHANGED
|
@@ -1,43 +1,29 @@
|
|
|
1
1
|
import { faker } from "@faker-js/faker";
|
|
2
|
-
import {
|
|
2
|
+
import { makeValueConfigFn } from "./utils";
|
|
3
3
|
|
|
4
4
|
/** Food [adjective](https://fakerjs.dev/api/food.html#adjective) */
|
|
5
|
-
export const adjective = (
|
|
6
|
-
...options: Parameters<typeof faker.food.adjective>
|
|
7
|
-
) => createValueConfig(() => faker.food.adjective(...options));
|
|
5
|
+
export const adjective = makeValueConfigFn(faker.food.adjective);
|
|
8
6
|
|
|
9
7
|
/** Food [description](https://fakerjs.dev/api/food.html#description) */
|
|
10
|
-
export const description = (
|
|
11
|
-
...options: Parameters<typeof faker.food.description>
|
|
12
|
-
) => createValueConfig(() => faker.food.description(...options));
|
|
8
|
+
export const description = makeValueConfigFn(faker.food.description);
|
|
13
9
|
|
|
14
10
|
/** Food [dish](https://fakerjs.dev/api/food.html#dish) */
|
|
15
|
-
export const dish = (
|
|
16
|
-
createValueConfig(() => faker.food.dish(...options));
|
|
11
|
+
export const dish = makeValueConfigFn(faker.food.dish);
|
|
17
12
|
|
|
18
13
|
/** Food [ethnicCategory](https://fakerjs.dev/api/food.html#ethnicCategory) */
|
|
19
|
-
export const ethnicCategory = (
|
|
20
|
-
...options: Parameters<typeof faker.food.ethnicCategory>
|
|
21
|
-
) => createValueConfig(() => faker.food.ethnicCategory(...options));
|
|
14
|
+
export const ethnicCategory = makeValueConfigFn(faker.food.ethnicCategory);
|
|
22
15
|
|
|
23
16
|
/** Food [fruit](https://fakerjs.dev/api/food.html#fruit) */
|
|
24
|
-
export const fruit = (
|
|
25
|
-
createValueConfig(() => faker.food.fruit(...options));
|
|
17
|
+
export const fruit = makeValueConfigFn(faker.food.fruit);
|
|
26
18
|
|
|
27
19
|
/** Food [ingredient](https://fakerjs.dev/api/food.html#ingredient) */
|
|
28
|
-
export const ingredient = (
|
|
29
|
-
...options: Parameters<typeof faker.food.ingredient>
|
|
30
|
-
) => createValueConfig(() => faker.food.ingredient(...options));
|
|
20
|
+
export const ingredient = makeValueConfigFn(faker.food.ingredient);
|
|
31
21
|
|
|
32
22
|
/** Food [meat](https://fakerjs.dev/api/food.html#meat) */
|
|
33
|
-
export const meat = (
|
|
34
|
-
createValueConfig(() => faker.food.meat(...options));
|
|
23
|
+
export const meat = makeValueConfigFn(faker.food.meat);
|
|
35
24
|
|
|
36
25
|
/** Food [spice](https://fakerjs.dev/api/food.html#spice) */
|
|
37
|
-
export const spice = (
|
|
38
|
-
createValueConfig(() => faker.food.spice(...options));
|
|
26
|
+
export const spice = makeValueConfigFn(faker.food.spice);
|
|
39
27
|
|
|
40
28
|
/** Food [vegetable](https://fakerjs.dev/api/food.html#vegetable) */
|
|
41
|
-
export const vegetable = (
|
|
42
|
-
...options: Parameters<typeof faker.food.vegetable>
|
|
43
|
-
) => createValueConfig(() => faker.food.vegetable(...options));
|
|
29
|
+
export const vegetable = makeValueConfigFn(faker.food.vegetable);
|