Skip to content

Commit d04de71

Browse files
authored
chore(deps-dev): bumping out of date deps (readmeio#181)
1 parent c085c36 commit d04de71

10 files changed

Lines changed: 333 additions & 100 deletions

File tree

package-lock.json

Lines changed: 299 additions & 66 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,20 +57,20 @@
5757
"test": "jest --coverage"
5858
},
5959
"devDependencies": {
60-
"@readme/eslint-config": "^10.5.3",
61-
"@types/eslint": "^8.40.0",
60+
"@readme/eslint-config": "^10.6.0",
61+
"@types/eslint": "^8.40.2",
6262
"@types/event-stream": "^4.0.1",
63-
"@types/har-format": "^1.2.8",
63+
"@types/har-format": "^1.2.11",
6464
"@types/jest": "^29.5.2",
65-
"@types/node": "^20.2.5",
65+
"@types/node": "^20.3.1",
6666
"@types/qs": "^6.9.7",
6767
"@types/stringify-object": "^4.0.2",
68-
"eslint": "^8.41.0",
68+
"eslint": "^8.43.0",
6969
"jest": "^29.5.0",
7070
"prettier": "^2.8.8",
7171
"require-directory": "^2.1.1",
7272
"ts-jest": "^29.1.0",
73-
"type-fest": "^3.11.1",
73+
"type-fest": "^3.12.0",
7474
"typescript": "^5.1.3"
7575
},
7676
"dependencies": {

src/fixtures/runCustomFixtures.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ import path from 'path';
1010
import { HTTPSnippet } from '..';
1111

1212
export interface CustomFixture {
13-
targetId: TargetId;
1413
clientId: ClientId;
14+
targetId: TargetId;
1515
tests: {
16-
it: string;
17-
input: Request;
18-
options: any;
19-
2016
/** a file path pointing to the expected custom fixture result */
2117
expected: string;
18+
19+
input: Request;
20+
it: string;
21+
options: any;
2222
}[];
2323
}
2424

src/index.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,8 @@ describe('HTTPSnippet', () => {
125125
expected: 'text/plain',
126126
},
127127
] as {
128-
input: keyof typeof mimetypes;
129128
expected: string;
129+
input: keyof typeof mimetypes;
130130
}[])('mimetype conversion of $input to $output', ({ input, expected }) => {
131131
const snippet = new HTTPSnippet(mimetypes[input]);
132132
const request = snippet.requests[0];

src/index.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -32,24 +32,24 @@ const debug = {
3232
* Then, in addition to that, it really adds to complexity with TypeScript (TypeScript takes this constraint very very seriously) in a way that's not actually super useful. So, we treat this object as though it could have both or either of `params` and/or `text`.
3333
*/
3434
type PostDataBase = PostDataCommon & {
35-
text?: string;
3635
params?: Param[];
36+
text?: string;
3737
};
3838

3939
export type HarRequest = Omit<NpmHarRequest, 'postData'> & { postData: PostDataBase };
4040

4141
export interface RequestExtras {
42+
allHeaders: ReducedHelperObject;
43+
cookiesObj: ReducedHelperObject;
44+
fullUrl: string;
45+
headersObj: ReducedHelperObject;
4246
postData: PostDataBase & {
47+
boundary?: string;
4348
jsonObj?: ReducedHelperObject;
4449
paramsObj?: ReducedHelperObject;
45-
boundary?: string;
4650
};
47-
fullUrl: string;
4851
queryObj: ReducedHelperObject;
49-
headersObj: ReducedHelperObject;
5052
uriObj: UrlWithParsedQuery;
51-
cookiesObj: ReducedHelperObject;
52-
allHeaders: ReducedHelperObject;
5353
}
5454

5555
export type Request = HarRequest & RequestExtras;
@@ -60,12 +60,12 @@ interface Entry {
6060

6161
interface HarEntry {
6262
log: {
63-
version: string;
6463
creator: {
6564
name: string;
6665
version: string;
6766
};
6867
entries: Entry[];
68+
version: string;
6969
};
7070
}
7171

src/targets/go/native/client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ import { CodeBuilder } from '../../../helpers/code-builder';
1313
import { escapeForDoubleQuotes } from '../../../helpers/escape';
1414

1515
export interface GoNativeOptions {
16-
showBoilerplate?: boolean;
1716
checkErrors?: boolean;
1817
printBody?: boolean;
18+
showBoilerplate?: boolean;
1919
timeout?: number;
2020
}
2121

src/targets/node/request/client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,11 +67,11 @@ export const request: Client = {
6767
}
6868

6969
let attachment: {
70-
value?: string;
7170
options?: {
72-
filename: string;
7371
contentType: string | null;
72+
filename: string;
7473
};
74+
value?: string;
7575
} = {};
7676

7777
if (param.fileName) {

src/targets/php/guzzle/client.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,10 @@ export const guzzle: Client<GuzzleOptions> = {
5454

5555
case 'multipart/form-data': {
5656
interface MultipartField {
57-
name: string;
58-
filename?: string;
5957
contents: string | undefined;
58+
filename?: string;
6059
headers?: Record<string, string>;
60+
name: string;
6161
}
6262

6363
const fields: MultipartField[] = [];

src/targets/php/http2/client.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,11 +55,11 @@ export const http2: Client<Http2Options> = {
5555
}
5656

5757
const files: {
58+
[anything: string]: string | undefined;
59+
data: string | undefined;
60+
file: string;
5861
name: string;
5962
type: string | undefined;
60-
file: string;
61-
data: string | undefined;
62-
[anything: string]: string | undefined;
6363
}[] = [];
6464
const fields: Record<string, any> = {};
6565
postData.params.forEach(({ name, fileName, value, contentType }) => {

src/targets/targets.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ export type TargetId = keyof typeof targets;
2626
export type ClientId = string;
2727

2828
export interface ClientInfo {
29+
description: string;
2930
key: ClientId;
30-
title: string;
3131
link: string;
32-
description: string;
32+
title: string;
3333
}
3434

3535
export type Converter<T extends Record<string, any>> = (
@@ -38,23 +38,23 @@ export type Converter<T extends Record<string, any>> = (
3838
) => string;
3939

4040
export interface Client<T extends Record<string, any> = Record<string, any>> {
41-
info: ClientInfo;
4241
convert: Converter<T>;
42+
info: ClientInfo;
4343
}
4444

4545
export type Extension = `.${string}` | null;
4646

4747
export interface TargetInfo {
48+
cli?: string;
49+
default: string;
50+
extname: Extension;
4851
key: TargetId;
4952
title: string;
50-
extname: Extension;
51-
default: string;
52-
cli?: string;
5353
}
5454

5555
export interface Target {
56-
info: TargetInfo;
5756
clientsById: Record<ClientId, Client>;
57+
info: TargetInfo;
5858
}
5959

6060
export const targets = {

0 commit comments

Comments
 (0)