Skip to content

Commit d0038b7

Browse files
authored
chore: upgrade prettier to 3.2.5 (orval-labs#1297)
* chore: upgrade `prettier` to `3.2.5` * chore: execute format auto correct
1 parent 9c11e7a commit d0038b7

34 files changed

+287
-319
lines changed

docs/jsconfig.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"compilerOptions": {
3-
"baseUrl": "./src",
4-
},
3+
"baseUrl": "./src"
4+
}
55
}

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@
5050
"husky": "^9.0.11",
5151
"lint-staged": "^15.2.2",
5252
"npm-run-all": "^4.1.5",
53-
"prettier": "3.2.4",
53+
"prettier": "3.2.5",
5454
"release-it": "^15.6.0",
5555
"rimraf": "^5.0.5",
5656
"tsup": "^8.0.2",

packages/angular/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts"],
3+
"include": ["src/**/*.ts"]
44
}

packages/axios/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts"],
3+
"include": ["src/**/*.ts"]
44
}

packages/core/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts", "../../types/**.d.ts"],
3+
"include": ["src/**/*.ts", "../../types/**.d.ts"]
44
}

packages/hono/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts"],
3+
"include": ["src/**/*.ts"]
44
}

packages/mock/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts"],
3+
"include": ["src/**/*.ts"]
44
}

packages/orval/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts", "../core/src/utils/fileExtensions.ts"],
3+
"include": ["src/**/*.ts", "../core/src/utils/fileExtensions.ts"]
44
}

packages/query/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts"],
3+
"include": ["src/**/*.ts"]
44
}

packages/swr/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts"],
3+
"include": ["src/**/*.ts"]
44
}

packages/zod/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
{
22
"extends": "../../tsconfig.base.json",
3-
"include": ["src/**/*.ts"],
3+
"include": ["src/**/*.ts"]
44
}

samples/angular-app/tsconfig.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@
1212
"importHelpers": true,
1313
"target": "es2015",
1414
"allowSyntheticDefaultImports": true,
15-
"lib": ["es2018", "dom"],
15+
"lib": ["es2018", "dom"]
1616
},
1717
"angularCompilerOptions": {
1818
"fullTemplateTypeCheck": true,
19-
"strictInjectionParameters": true,
20-
},
19+
"strictInjectionParameters": true
20+
}
2121
}

samples/basic/api/endpoints/petstoreFromFileSpec.ts

+27-37
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,18 @@
44
* Swagger Petstore
55
* OpenAPI spec version: 1.0.0
66
*/
7-
import axios from 'axios'
8-
import type {
9-
AxiosRequestConfig,
10-
AxiosResponse
11-
} from 'axios'
7+
import axios from 'axios';
8+
import type { AxiosRequestConfig, AxiosResponse } from 'axios';
129
export type CreatePetsBody = {
1310
name: string;
1411
tag: string;
1512
};
1613

1714
export type ListPetsParams = {
18-
/**
19-
* How many items to return at one time (max 100)
20-
*/
21-
limit?: string;
15+
/**
16+
* How many items to return at one time (max 100)
17+
*/
18+
limit?: string;
2219
};
2320

2421
export interface Error {
@@ -54,46 +51,39 @@ export interface Pet {
5451
*/
5552
export type Pets = Pet[];
5653

57-
58-
59-
60-
61-
/**
54+
/**
6255
* @summary List all pets
6356
*/
6457
export const listPets = <TData = AxiosResponse<Pets>>(
65-
params?: ListPetsParams, options?: AxiosRequestConfig
66-
): Promise<TData> => {
67-
return axios.get(
68-
`/pets`,{
58+
params?: ListPetsParams,
59+
options?: AxiosRequestConfig,
60+
): Promise<TData> => {
61+
return axios.get(`/pets`, {
6962
...options,
70-
params: {...params, ...options?.params},}
71-
);
72-
}
63+
params: { ...params, ...options?.params },
64+
});
65+
};
7366

7467
/**
7568
* @summary Create a pet
7669
*/
7770
export const createPets = <TData = AxiosResponse<void>>(
78-
createPetsBody: CreatePetsBody, options?: AxiosRequestConfig
79-
): Promise<TData> => {
80-
return axios.post(
81-
`/pets`,
82-
createPetsBody,options
83-
);
84-
}
71+
createPetsBody: CreatePetsBody,
72+
options?: AxiosRequestConfig,
73+
): Promise<TData> => {
74+
return axios.post(`/pets`, createPetsBody, options);
75+
};
8576

8677
/**
8778
* @summary Info for a specific pet
8879
*/
8980
export const showPetById = <TData = AxiosResponse<Pet>>(
90-
petId: string, options?: AxiosRequestConfig
91-
): Promise<TData> => {
92-
return axios.get(
93-
`/pets/${petId}`,options
94-
);
95-
}
81+
petId: string,
82+
options?: AxiosRequestConfig,
83+
): Promise<TData> => {
84+
return axios.get(`/pets/${petId}`, options);
85+
};
9686

97-
export type ListPetsResult = AxiosResponse<Pets>
98-
export type CreatePetsResult = AxiosResponse<void>
99-
export type ShowPetByIdResult = AxiosResponse<Pet>
87+
export type ListPetsResult = AxiosResponse<Pets>;
88+
export type CreatePetsResult = AxiosResponse<void>;
89+
export type ShowPetByIdResult = AxiosResponse<Pet>;

samples/basic/api/endpoints/petstoreFromFileSpecWithConfig.ts

+27-37
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,18 @@
44
* Swagger Petstore
55
* OpenAPI spec version: 1.0.0
66
*/
7-
import axios from 'axios'
8-
import type {
9-
AxiosRequestConfig,
10-
AxiosResponse
11-
} from 'axios'
7+
import axios from 'axios';
8+
import type { AxiosRequestConfig, AxiosResponse } from 'axios';
129
export type CreatePetsBody = {
1310
name: string;
1411
tag: string;
1512
};
1613

1714
export type ListPetsParams = {
18-
/**
19-
* How many items to return at one time (max 100)
20-
*/
21-
limit?: string;
15+
/**
16+
* How many items to return at one time (max 100)
17+
*/
18+
limit?: string;
2219
};
2320

2421
export interface Error {
@@ -54,46 +51,39 @@ export interface Pet {
5451
*/
5552
export type Pets = Pet[];
5653

57-
58-
59-
60-
61-
/**
54+
/**
6255
* @summary List all pets
6356
*/
6457
export const listPets = <TData = AxiosResponse<Pets>>(
65-
params?: ListPetsParams, options?: AxiosRequestConfig
66-
): Promise<TData> => {
67-
return axios.get(
68-
`/pets`,{
58+
params?: ListPetsParams,
59+
options?: AxiosRequestConfig,
60+
): Promise<TData> => {
61+
return axios.get(`/pets`, {
6962
...options,
70-
params: {...params, ...options?.params},}
71-
);
72-
}
63+
params: { ...params, ...options?.params },
64+
});
65+
};
7366

7467
/**
7568
* @summary Create a pet
7669
*/
7770
export const createPets = <TData = AxiosResponse<void>>(
78-
createPetsBody: CreatePetsBody, options?: AxiosRequestConfig
79-
): Promise<TData> => {
80-
return axios.post(
81-
`/pets`,
82-
createPetsBody,options
83-
);
84-
}
71+
createPetsBody: CreatePetsBody,
72+
options?: AxiosRequestConfig,
73+
): Promise<TData> => {
74+
return axios.post(`/pets`, createPetsBody, options);
75+
};
8576

8677
/**
8778
* @summary Info for a specific pet
8879
*/
8980
export const showPetById = <TData = AxiosResponse<Pet>>(
90-
petId: string, options?: AxiosRequestConfig
91-
): Promise<TData> => {
92-
return axios.get(
93-
`/pets/${petId}`,options
94-
);
95-
}
81+
petId: string,
82+
options?: AxiosRequestConfig,
83+
): Promise<TData> => {
84+
return axios.get(`/pets/${petId}`, options);
85+
};
9686

97-
export type ListPetsResult = AxiosResponse<Pets>
98-
export type CreatePetsResult = AxiosResponse<void>
99-
export type ShowPetByIdResult = AxiosResponse<Pet>
87+
export type ListPetsResult = AxiosResponse<Pets>;
88+
export type CreatePetsResult = AxiosResponse<void>;
89+
export type ShowPetByIdResult = AxiosResponse<Pet>;

0 commit comments

Comments
 (0)