Skip to content

Commit 23cba09

Browse files
authored
chore: upgrade @typescript-eslint packages (#1580)
1 parent 3a18d23 commit 23cba09

File tree

11 files changed

+140
-107
lines changed

11 files changed

+140
-107
lines changed

.changeset/sour-singers-chew.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
---
2+
---

.eslintrc.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,14 @@ module.exports = {
2121
"prefer-rest-params": "off",
2222
"@typescript-eslint/no-non-null-assertion": "off",
2323

24+
// intentional usage
25+
"@typescript-eslint/no-empty-object-type": "off",
26+
"@typescript-eslint/no-unsafe-function-type": "off",
27+
28+
// temporary until upgrading ESLint
29+
"@typescript-eslint/no-unused-vars": "off",
30+
"@typescript-eslint/no-require-imports": "off",
31+
2432
/** Warnings */
2533
"@typescript-eslint/no-namespace": "warn",
2634

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@
3939
"@tsconfig/recommended": "1.0.2",
4040
"@types/jest": "28.1.3",
4141
"@types/jsdom": "20.0.1",
42-
"@typescript-eslint/eslint-plugin": "7.8.0",
43-
"@typescript-eslint/parser": "7.8.0",
42+
"@typescript-eslint/eslint-plugin": "8.32.0",
43+
"@typescript-eslint/parser": "8.32.0",
4444
"esbuild": "0.19.11",
4545
"eslint": "8.57.0",
4646
"eslint-plugin-simple-import-sort": "7.0.0",

packages/eventstream-codec/src/MessageEncoderStream.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { Message, MessageEncoder } from "@smithy/types";
66
export interface MessageEncoderStreamOptions {
77
messageStream: AsyncIterable<Message>;
88
encoder: MessageEncoder;
9-
includeEndFrame?: Boolean;
9+
includeEndFrame?: boolean;
1010
}
1111

1212
/**

packages/eventstream-codec/src/SmithyMessageDecoderStream.spec.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,12 @@ describe("SmithyMessageDecoderStream", () => {
2424
yield message2;
2525
};
2626

27-
const stream = new SmithyMessageDecoderStream<String>({
27+
const stream = new SmithyMessageDecoderStream<string>({
2828
messageStream: inputStream(),
2929
deserializer: deserializer,
3030
});
3131

32-
const messages: Array<String> = [];
32+
const messages: Array<string> = [];
3333
for await (const str of stream) {
3434
messages.push(str);
3535
}

packages/eventstream-codec/src/SmithyMessageEncoderStream.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ describe("SmithyMessageEncoderStream", () => {
2222
yield "second";
2323
};
2424

25-
const stream = new SmithyMessageEncoderStream<String>({
25+
const stream = new SmithyMessageEncoderStream<string>({
2626
inputStream: inputStream(),
2727
serializer: serializer,
2828
});

packages/smithy-client/src/date-utils.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
import { strictParseByte, strictParseDouble, strictParseFloat32, strictParseShort } from "./parse-utils";
33

44
// Build indexes outside so we allocate them once.
5-
const DAYS: Array<String> = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
5+
const DAYS: Array<string> = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
66

77
// These must be kept in order
88
// prettier-ignore
9-
const MONTHS: Array<String> = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
9+
const MONTHS: Array<string> = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
1010

1111
/**
1212
* @internal

packages/smithy-client/src/lazy-json.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable @typescript-eslint/no-wrapper-object-types */
12
/**
23
* @public
34
*
@@ -14,7 +15,6 @@ export type AutomaticJsonStringConversion = Parameters<typeof JSON.stringify>[0]
1415

1516
/**
1617
* @internal
17-
*
1818
*/
1919
export interface LazyJsonString extends String {
2020
/**

private/util-test/src/test-http-handler.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,15 @@ const MOCK_CREDENTIALS = {
3636
secretAccessKey: "MOCK_SECRET_ACCESS_KEY_ID",
3737
};
3838

39-
interface TestHttpHandlerConfig {}
39+
type TestHttpHandlerConfig = object;
4040

4141
/**
4242
* Supplied to test clients to assert correct requests.
4343
* @internal
4444
*/
4545
export class TestHttpHandler implements HttpHandler<TestHttpHandlerConfig> {
4646
private static WATCHER = Symbol("TestHttpHandler_WATCHER");
47-
private originalSend?: Function;
47+
private originalSend?: Client<any, any, any>["send"];
4848
private originalRequestHandler?: RequestHandler<any, any, any>;
4949
private client?: Client<any, any, any>;
5050
private assertions = 0;

smithy-typescript-ssdk-libs/server-node/src/index.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ beforeAll(async () => {
2929

3030
let resToEnd: ServerResponse;
3131

32-
function getRequest(options: RequestOptions & { body?: String }): Promise<[IncomingMessage, ServerResponse]> {
32+
function getRequest(options: RequestOptions & { body?: string }): Promise<[IncomingMessage, ServerResponse]> {
3333
return new Promise((resolve) => {
3434
promiseResolve = resolve;
3535
request({

0 commit comments

Comments
 (0)