struct-fakerator 2.4.5 → 2.4.7
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/dist/chunk-3FFGDXA5.mjs +48 -0
- package/dist/{chunk-HADENNJW.js → chunk-3MYH2PDS.js} +5 -3
- package/dist/chunk-4ESFUYHU.js +48 -0
- package/dist/chunk-4XQBQAPC.mjs +33 -0
- package/dist/{chunk-J266ZY25.mjs → chunk-5M3DUBFV.mjs} +6 -4
- package/dist/chunk-62NUC6UZ.js +51 -0
- package/dist/chunk-7IQW6MWT.mjs +81 -0
- package/dist/{chunk-TX7HRLKE.mjs → chunk-7V3T6MQ3.mjs} +5 -3
- package/dist/chunk-AWKBY27N.js +35 -0
- package/dist/{chunk-7R4M2AAS.js → chunk-BGE4WZH7.js} +6 -4
- package/dist/chunk-BNUCXH6Q.js +49 -0
- package/dist/{chunk-YY2TF7WC.mjs → chunk-CC255UJD.mjs} +7 -5
- package/dist/chunk-CK65OFQQ.mjs +56 -0
- package/dist/chunk-FG2O523S.js +48 -0
- package/dist/chunk-GF4PSVJ7.js +81 -0
- package/dist/{chunk-7YNCYSJY.js → chunk-GL777PKT.js} +4 -2
- package/dist/{chunk-BXJJGEM5.js → chunk-GR5EJCJ2.js} +5 -3
- package/dist/chunk-HAIK2LXD.js +63 -0
- package/dist/chunk-HK4L636Y.mjs +49 -0
- package/dist/chunk-HMGGQ5ZJ.js +45 -0
- package/dist/chunk-IZVHA6FO.js +45 -0
- package/dist/{chunk-CFX43E3I.mjs → chunk-JFYN4RCQ.mjs} +6 -4
- package/dist/{chunk-LBQLRQOQ.js → chunk-KB4QNLUX.js} +7 -5
- package/dist/chunk-KK4QURZV.mjs +63 -0
- package/dist/chunk-KLYK2EDS.js +18 -0
- package/dist/chunk-L63CILKL.js +36 -0
- package/dist/chunk-LCQV5ZXR.js +63 -0
- package/dist/chunk-M7SBPX3E.mjs +45 -0
- package/dist/chunk-MJWNNESP.js +57 -0
- package/dist/chunk-MKTV5ZCC.mjs +30 -0
- package/dist/chunk-MNRDBDJD.js +33 -0
- package/dist/chunk-MTNLYYS2.mjs +51 -0
- package/dist/chunk-NPYKAZ5O.mjs +42 -0
- package/dist/chunk-PS673ZMG.mjs +78 -0
- package/dist/chunk-RCDDW7NN.js +36 -0
- package/dist/chunk-RWSXJDFQ.mjs +57 -0
- package/dist/chunk-SAYLPMKP.js +74 -0
- package/dist/chunk-SOFVWH6A.js +56 -0
- package/dist/chunk-T4IVAGFU.mjs +48 -0
- package/dist/chunk-TKS2PTMF.mjs +18 -0
- package/dist/chunk-UOSN6FPU.js +42 -0
- package/dist/chunk-V4JFB4H6.mjs +45 -0
- package/dist/chunk-XJ3B37LJ.js +45 -0
- package/dist/chunk-XKWYGGIM.mjs +36 -0
- package/dist/chunk-XMR5DWYS.mjs +74 -0
- package/dist/chunk-XYNVAWSB.mjs +45 -0
- package/dist/chunk-YNT5L5UH.js +78 -0
- package/dist/chunk-YRRALMO4.mjs +36 -0
- package/dist/chunk-Z5HPFZ65.mjs +35 -0
- package/dist/chunk-ZKVLWCGR.mjs +63 -0
- package/dist/utils/airline.js +3 -2
- package/dist/utils/airline.mjs +2 -1
- package/dist/utils/animal.js +3 -2
- package/dist/utils/animal.mjs +2 -1
- package/dist/utils/color.js +3 -2
- package/dist/utils/color.mjs +2 -1
- package/dist/utils/commerce.js +3 -2
- package/dist/utils/commerce.mjs +2 -1
- package/dist/utils/company.js +3 -2
- package/dist/utils/company.mjs +2 -1
- package/dist/utils/database.js +3 -2
- package/dist/utils/database.mjs +2 -1
- package/dist/utils/datatype.js +3 -2
- package/dist/utils/datatype.mjs +2 -1
- package/dist/utils/datetime.js +3 -2
- package/dist/utils/datetime.mjs +2 -1
- package/dist/utils/finance.js +3 -2
- package/dist/utils/finance.mjs +2 -1
- package/dist/utils/food.js +3 -2
- package/dist/utils/food.mjs +2 -1
- package/dist/utils/git.js +3 -2
- package/dist/utils/git.mjs +2 -1
- package/dist/utils/hacker.js +3 -2
- package/dist/utils/hacker.mjs +2 -1
- package/dist/utils/image.js +3 -2
- package/dist/utils/image.mjs +2 -1
- package/dist/utils/index.d.mts +1 -0
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/index.js +29 -25
- package/dist/utils/index.mjs +29 -25
- package/dist/utils/internet.js +3 -2
- package/dist/utils/internet.mjs +2 -1
- package/dist/utils/location.js +3 -2
- package/dist/utils/location.mjs +2 -1
- package/dist/utils/lorem.js +3 -2
- package/dist/utils/lorem.mjs +2 -1
- package/dist/utils/music.js +3 -2
- package/dist/utils/music.mjs +2 -1
- package/dist/utils/number.js +3 -2
- package/dist/utils/number.mjs +2 -1
- package/dist/utils/person.js +3 -2
- package/dist/utils/person.mjs +2 -1
- package/dist/utils/phone.js +3 -2
- package/dist/utils/phone.mjs +2 -1
- package/dist/utils/science.js +3 -2
- package/dist/utils/science.mjs +2 -1
- package/dist/utils/string.js +3 -2
- package/dist/utils/string.mjs +2 -1
- package/dist/utils/system.js +3 -2
- package/dist/utils/system.mjs +2 -1
- package/dist/utils/utils.d.mts +2 -0
- package/dist/utils/utils.d.ts +2 -0
- package/dist/utils/utils.js +7 -0
- package/dist/utils/utils.mjs +7 -0
- package/dist/utils/vehicle.js +3 -2
- package/dist/utils/vehicle.mjs +2 -1
- package/dist/utils/word.js +12 -11
- package/dist/utils/word.mjs +13 -12
- package/dist/utils-BiDlGzTl.d.mts +10 -0
- package/dist/utils-DinJc3Cq.d.ts +10 -0
- package/package.json +13 -13
- 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/chunk-2R3Q64AD.mjs +0 -28
- package/dist/chunk-5U5KT6H4.js +0 -61
- package/dist/chunk-7GE2A5VT.mjs +0 -43
- 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-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-HHL3SY7A.js +0 -34
- package/dist/chunk-HOVGSNA4.js +0 -73
- package/dist/chunk-J3IXKUJK.js +0 -61
- package/dist/chunk-J5ZX7PK3.js +0 -34
- package/dist/chunk-L7PFM742.mjs +0 -49
- package/dist/chunk-LJKI4ZZ5.mjs +0 -43
- package/dist/chunk-M2J3MAM7.mjs +0 -52
- package/dist/chunk-NEE5QKPY.mjs +0 -40
- 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-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-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-ZPQWZLYI.js +0 -43
- package/dist/chunk-ZRQDW34U.mjs +0 -76
package/dist/utils/word.mjs
CHANGED
|
@@ -1,20 +1,21 @@
|
|
|
1
|
+
import {
|
|
2
|
+
makeValueConfigFn
|
|
3
|
+
} from "../chunk-TKS2PTMF.mjs";
|
|
1
4
|
import {
|
|
2
5
|
f
|
|
3
6
|
} from "../chunk-BS7IEV74.mjs";
|
|
4
|
-
import
|
|
5
|
-
createValueConfig
|
|
6
|
-
} from "../chunk-OLSCXZ3D.mjs";
|
|
7
|
+
import "../chunk-OLSCXZ3D.mjs";
|
|
7
8
|
|
|
8
9
|
// src/utils/word.ts
|
|
9
|
-
var adjective = (
|
|
10
|
-
var adverb = (
|
|
11
|
-
var conjunction = (
|
|
12
|
-
var interjection = (
|
|
13
|
-
var noun = (
|
|
14
|
-
var preposition = (
|
|
15
|
-
var sample = (
|
|
16
|
-
var verb = (
|
|
17
|
-
var words = (
|
|
10
|
+
var adjective = makeValueConfigFn(f.word.adjective);
|
|
11
|
+
var adverb = makeValueConfigFn(f.word.adverb);
|
|
12
|
+
var conjunction = makeValueConfigFn(f.word.conjunction);
|
|
13
|
+
var interjection = makeValueConfigFn(f.word.interjection);
|
|
14
|
+
var noun = makeValueConfigFn(f.word.noun);
|
|
15
|
+
var preposition = makeValueConfigFn(f.word.preposition);
|
|
16
|
+
var sample = makeValueConfigFn(f.word.sample);
|
|
17
|
+
var verb = makeValueConfigFn(f.word.verb);
|
|
18
|
+
var words = makeValueConfigFn(f.word.words);
|
|
18
19
|
export {
|
|
19
20
|
adjective,
|
|
20
21
|
adverb,
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { V as ValueConfig } from './type-C8Ny1fB6.mjs';
|
|
2
|
+
|
|
3
|
+
declare function makeValueConfigFn<Args extends Array<unknown>, R>(fn: (...options: Args) => R): (...options: Args) => ValueConfig<R>;
|
|
4
|
+
|
|
5
|
+
declare const utils_makeValueConfigFn: typeof makeValueConfigFn;
|
|
6
|
+
declare namespace utils {
|
|
7
|
+
export { utils_makeValueConfigFn as makeValueConfigFn };
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export { makeValueConfigFn as m, utils as u };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { V as ValueConfig } from './type-C8Ny1fB6.js';
|
|
2
|
+
|
|
3
|
+
declare function makeValueConfigFn<Args extends Array<unknown>, R>(fn: (...options: Args) => R): (...options: Args) => ValueConfig<R>;
|
|
4
|
+
|
|
5
|
+
declare const utils_makeValueConfigFn: typeof makeValueConfigFn;
|
|
6
|
+
declare namespace utils {
|
|
7
|
+
export { utils_makeValueConfigFn as makeValueConfigFn };
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export { makeValueConfigFn as m, utils as u };
|
package/package.json
CHANGED
|
@@ -1,16 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "struct-fakerator",
|
|
3
|
-
"version": "2.4.
|
|
3
|
+
"version": "2.4.7",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
8
8
|
"exports": {
|
|
9
9
|
".": {
|
|
10
|
-
"default": {
|
|
11
|
-
"types": "./dist/index.d.ts",
|
|
12
|
-
"default": "./dist/index.mjs"
|
|
13
|
-
},
|
|
14
10
|
"require": {
|
|
15
11
|
"types": "./dist/index.d.ts",
|
|
16
12
|
"default": "./dist/index.js"
|
|
@@ -22,13 +18,13 @@
|
|
|
22
18
|
"module": {
|
|
23
19
|
"types": "./dist/index.d.ts",
|
|
24
20
|
"default": "./dist/index.mjs"
|
|
21
|
+
},
|
|
22
|
+
"default": {
|
|
23
|
+
"types": "./dist/index.d.ts",
|
|
24
|
+
"default": "./dist/index.mjs"
|
|
25
25
|
}
|
|
26
26
|
},
|
|
27
27
|
"./utils": {
|
|
28
|
-
"default": {
|
|
29
|
-
"types": "./dist/utils/index.d.ts",
|
|
30
|
-
"default": "./dist/utils/index.mjs"
|
|
31
|
-
},
|
|
32
28
|
"require": {
|
|
33
29
|
"types": "./dist/utils/index.d.ts",
|
|
34
30
|
"default": "./dist/utils/index.js"
|
|
@@ -40,13 +36,13 @@
|
|
|
40
36
|
"module": {
|
|
41
37
|
"types": "./dist/utils/index.d.ts",
|
|
42
38
|
"default": "./dist/utils/index.mjs"
|
|
39
|
+
},
|
|
40
|
+
"default": {
|
|
41
|
+
"types": "./dist/utils/index.d.ts",
|
|
42
|
+
"default": "./dist/utils/index.mjs"
|
|
43
43
|
}
|
|
44
44
|
},
|
|
45
45
|
"./utils/*": {
|
|
46
|
-
"default": {
|
|
47
|
-
"types": "./dist/utils/*.d.ts",
|
|
48
|
-
"default": "./dist/utils/*.mjs"
|
|
49
|
-
},
|
|
50
46
|
"require": {
|
|
51
47
|
"types": "./dist/utils/*.d.ts",
|
|
52
48
|
"default": "./dist/utils/*.js"
|
|
@@ -58,6 +54,10 @@
|
|
|
58
54
|
"module": {
|
|
59
55
|
"types": "./dist/utils/*.d.ts",
|
|
60
56
|
"default": "./dist/utils/*.mjs"
|
|
57
|
+
},
|
|
58
|
+
"default": {
|
|
59
|
+
"types": "./dist/utils/*.d.ts",
|
|
60
|
+
"default": "./dist/utils/*.mjs"
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
63
|
},
|
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);
|