Skip to content

Commit afe723e

Browse files
committed
Merge branch 'next' into pr/suyashgulati/3130
2 parents d9cceb4 + e271d4a commit afe723e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+2567
-510
lines changed

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// README at: https://github.com/devcontainers/templates/tree/main/src/typescript-node
33
{
44
"name": "FakerJs",
5-
"image": "mcr.microsoft.com/devcontainers/typescript-node:22@sha256:8fac147b83828b1ea661bffd850bd03a6a3f3229d8349b9880d86e55e0d25569",
5+
"image": "mcr.microsoft.com/devcontainers/typescript-node:22@sha256:79c4181532784148abe5d0dd37505f420674990fd104f8294fd06155003fa442",
66

77
// Features to add to the dev container. More info: https://containers.dev/features.
88
// "features": {},

.github/renovate.json5

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
},
5858
{
5959
"groupName": "doc-dependencies",
60-
"matchPackageNames": ["@algolia/client-search", "ts-morph", "vitepress"]
60+
"matchPackageNames": ["ts-morph", "vitepress"]
6161
}
6262
],
6363
"stopUpdatingLabel": "s: on hold",

.github/workflows/check-release-pr.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,12 +17,12 @@ jobs:
1717

1818
steps:
1919
- name: Checkout faker
20-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
20+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
2121
with:
2222
path: faker
2323

2424
- name: Checkout playground
25-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
25+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
2626
with:
2727
repository: faker-js/playground
2828
path: playground

.github/workflows/ci.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
name: 'Build & Unit Test: node-${{ matrix.node_version }}, ${{ matrix.os }}'
2323
steps:
2424
- name: Checkout
25-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
25+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
2626
with:
2727
# Required for docs/versions tests
2828
fetch-depth: 0
@@ -70,7 +70,7 @@ jobs:
7070
run: date
7171

7272
- name: Checkout
73-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
73+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
7474
with:
7575
# Required for docs/versions tests
7676
fetch-depth: 0
@@ -104,7 +104,7 @@ jobs:
104104
name: 'E2E Doc Test: node-22, ubuntu-latest'
105105
steps:
106106
- name: Checkout
107-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
107+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
108108

109109
- name: Install pnpm
110110
uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # v4.0.0
@@ -125,7 +125,7 @@ jobs:
125125
name: 'Lint: node-22, ubuntu-latest'
126126
steps:
127127
- name: Checkout
128-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
128+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
129129
with:
130130
fetch-depth: 0
131131

@@ -155,7 +155,7 @@ jobs:
155155
name: 'TS-Check: node-22, ubuntu-latest'
156156
steps:
157157
- name: Checkout
158-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
158+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
159159
with:
160160
fetch-depth: 0
161161

@@ -185,7 +185,7 @@ jobs:
185185
name: 'Codecov: node-22, ubuntu-latest'
186186
steps:
187187
- name: Checkout
188-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
188+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
189189
with:
190190
fetch-depth: 0
191191

@@ -210,7 +210,7 @@ jobs:
210210
run: pnpm vitest run --coverage
211211

212212
- name: Upload coverage to Codecov
213-
uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 # v4.5.0
213+
uses: codecov/codecov-action@b9fd7d16f6d7d1b5d2bec1a2887e65ceed900238 # v4.6.0
214214
with:
215215
token: ${{ secrets.CODECOV_TOKEN }}
216216
fail_ci_if_error: true

.github/workflows/draft-release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121

2222
steps:
2323
- name: Checkout
24-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
24+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
2525
with:
2626
fetch-depth: 0 # we need the tags and the commit history for the gh release create command
2727
ref: ${{ github.event.pull_request.base.ref }}

.github/workflows/pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414

1515
steps:
1616
- name: Checkout
17-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
17+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
1818
with:
1919
fetch-depth: 0
2020

.github/workflows/preflight-comment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
name: 'Comment Code Generation'
1717
steps:
1818
- name: Checkout
19-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
19+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
2020
with:
2121
ref: 'next'
2222

.github/workflows/prepare-release-pr.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424

2525
steps:
2626
- name: Checkout
27-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
27+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
2828
with:
2929
fetch-depth: 0
3030
token: ${{ secrets.GH_TOKEN }}

.github/workflows/publish-release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515

1616
steps:
1717
- name: Checkout
18-
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
18+
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
1919
with:
2020
fetch-depth: 0 # we want to push the release branch later
2121
token: ${{ secrets.GH_TOKEN }}

docs/.vitepress/api-pages.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ export const apiPages = [
1111
items: [
1212
{ text: 'Airline', link: '/api/airline.html' },
1313
{ text: 'Animal', link: '/api/animal.html' },
14+
{ text: 'Book', link: '/api/book.html' },
1415
{ text: 'Color', link: '/api/color.html' },
1516
{ text: 'Commerce', link: '/api/commerce.html' },
1617
{ text: 'Company', link: '/api/company.html' },

docs/guide/unique.md

Lines changed: 1 addition & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -25,34 +25,4 @@ faker.helpers.uniqueArray(faker.internet.email, 1000); // will generate 1000 uni
2525

2626
3. Build your own logic to keep track of a set of previously generated values and regenerate values as necessary if a duplicate is generated
2727

28-
4. Use a third party package to enforce uniqueness such as [enforce-unique](https://github.com/MansurAliKoroglu/enforce-unique)
29-
30-
Note you can supply a maximum time (in milliseconds) or maximum number of retries.
31-
32-
```js
33-
import { EnforceUniqueError, UniqueEnforcer } from 'enforce-unique';
34-
35-
const uniqueEnforcerEmail = new UniqueEnforcer();
36-
37-
function createRandomUser() {
38-
const firstName = faker.person.firstName();
39-
const lastName = faker.person.lastName();
40-
const email = uniqueEnforcerEmail.enforce(
41-
() =>
42-
faker.internet.email({
43-
firstName,
44-
lastName,
45-
}),
46-
{
47-
maxTime: 50,
48-
maxRetries: 50,
49-
}
50-
);
51-
52-
return {
53-
firstName,
54-
lastName,
55-
email,
56-
};
57-
}
58-
```
28+
4. Use a third-party package to enforce uniqueness, such as [enforce-unique](https://github.com/MansurAliKoroglu/enforce-unique) or [@dpaskhin/unique](https://github.com/dPaskhin/unique).

docs/guide/upgrading.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ This is the migration guide for upgrading from v8 to v9.
1414

1515
:::
1616

17-
v9 has not yet been released. This page contains a work-in-progress list of breaking changes in v9.
18-
1917
## General Breaking Changes
2018

2119
### Requires Node v18+

eslint.config.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,6 @@ const config: ReturnType<typeof tseslint.config> = tseslint.config(
153153

154154
// TODO @Shinigami92 2023-09-23: The following rules currently conflict with our code.
155155
// Each rule should be checked whether it should be enabled/configured and the problems fixed, or stay disabled permanently.
156-
'unicorn/better-regex': 'off',
157156
'unicorn/consistent-function-scoping': 'off',
158157
'unicorn/no-object-as-default-parameter': 'off',
159158
'unicorn/prefer-export-from': 'off',

package.json

Lines changed: 20 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -104,48 +104,46 @@
104104
],
105105
"devDependencies": {
106106
"@actions/github": "6.0.0",
107-
"@algolia/client-search": "5.5.3",
108-
"@eslint/compat": "1.1.1",
109-
"@eslint/js": "9.11.0",
110-
"@stylistic/eslint-plugin": "2.8.0",
107+
"@eslint/compat": "1.2.0",
108+
"@eslint/js": "9.12.0",
109+
"@stylistic/eslint-plugin": "2.9.0",
111110
"@types/eslint__js": "8.42.3",
112-
"@types/node": "20.16.5",
111+
"@types/node": "20.16.11",
113112
"@types/sanitize-html": "2.13.0",
114113
"@types/semver": "7.5.8",
115114
"@types/validator": "13.12.2",
116-
"@vitest/coverage-v8": "2.1.1",
117-
"@vitest/eslint-plugin": "1.1.4",
118-
"@vitest/ui": "2.1.1",
115+
"@vitest/coverage-v8": "2.1.2",
116+
"@vitest/eslint-plugin": "1.1.7",
117+
"@vitest/ui": "2.1.2",
119118
"@vueuse/core": "11.1.0",
120119
"commit-and-tag-version": "12.4.4",
121-
"cypress": "13.14.2",
122-
"eslint": "9.11.0",
120+
"cypress": "13.15.0",
121+
"eslint": "9.12.0",
123122
"eslint-config-prettier": "9.1.0",
124-
"eslint-define-config": "2.1.0",
125-
"eslint-plugin-jsdoc": "50.2.4",
123+
"eslint-plugin-jsdoc": "50.3.1",
126124
"eslint-plugin-prettier": "5.2.1",
127-
"eslint-plugin-unicorn": "55.0.0",
125+
"eslint-plugin-unicorn": "56.0.0",
128126
"jiti": "1.21.6",
129127
"npm-run-all2": "6.2.3",
130128
"prettier": "3.3.3",
131129
"prettier-plugin-organize-imports": "4.1.0",
132-
"prettier-plugin-packagejson": "2.5.2",
130+
"prettier-plugin-packagejson": "2.5.3",
133131
"rimraf": "5.0.10",
134-
"sanitize-html": "2.13.0",
132+
"sanitize-html": "2.13.1",
135133
"semver": "7.6.3",
136-
"ts-morph": "23.0.0",
134+
"ts-morph": "24.0.0",
137135
"tsup": "8.3.0",
138136
"tsx": "4.19.1",
139137
"typescript": "5.6.2",
140-
"typescript-eslint": "8.7.0",
138+
"typescript-eslint": "8.8.1",
141139
"validator": "13.12.0",
142-
"vite": "5.4.7",
143-
"vitepress": "1.3.4",
144-
"vitest": "2.1.1",
145-
"vue": "3.5.8",
140+
"vite": "5.4.8",
141+
"vitepress": "1.4.0",
142+
"vitest": "2.1.2",
143+
"vue": "3.5.11",
146144
"vue-tsc": "2.1.6"
147145
},
148-
"packageManager": "pnpm@9.11.0",
146+
"packageManager": "pnpm@9.12.1",
149147
"engines": {
150148
"node": ">=18.0.0",
151149
"npm": ">=9.0.0"

0 commit comments

Comments
 (0)