diff --git a/its/ruling/src/test/expected/jsts/router/javascript-S1874.json b/its/ruling/src/test/expected/jsts/router/javascript-S1874.json index ff16bac545c..807f010b3db 100644 --- a/its/ruling/src/test/expected/jsts/router/javascript-S1874.json +++ b/its/ruling/src/test/expected/jsts/router/javascript-S1874.json @@ -4,7 +4,6 @@ 100 ], "router:third_party/brick/brick-1.0.1.byob.js": [ -337, 877, 1412, 1637, diff --git a/package-lock.json b/package-lock.json index ac749311703..33339be213b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -48,7 +48,7 @@ "stylelint": "15.11.0", "tar": "7.4.3", "tmp": "0.2.3", - "typescript": "5.6.3", + "typescript": "5.7.2", "vue-eslint-parser": "9.4.3", "yaml": "2.6.1" }, @@ -11432,9 +11432,9 @@ } }, "node_modules/typescript": { - "version": "5.6.3", - "resolved": "https://repox.jfrog.io/artifactory/api/npm/npm/typescript/-/typescript-5.6.3.tgz", - "integrity": "sha512-hjcS1mhfuyi4WW8IWtjP7brDrG2cuDZukyrYrSauoXGNgx0S7zceP07adYkJycEr56BOUTNPzbInooiN3fn1qw==", + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.7.2.tgz", + "integrity": "sha512-i5t66RHxDvVN40HfDd1PsEThGNnlMCMT3jMUuoh9/0TaqWevNontacunWyN02LA9/fIbEWlcHZcgTKb9QoaLfg==", "license": "Apache-2.0", "bin": { "tsc": "bin/tsc", diff --git a/package.json b/package.json index d9a5c5c6632..11e83a1c7d0 100644 --- a/package.json +++ b/package.json @@ -136,7 +136,7 @@ "stylelint": "15.11.0", "tar": "7.4.3", "tmp": "0.2.3", - "typescript": "5.6.3", + "typescript": "5.7.2", "vue-eslint-parser": "9.4.3", "yaml": "2.6.1" }, diff --git a/packages/jsts/src/rules/S3800/rule.ts b/packages/jsts/src/rules/S3800/rule.ts index 7f4df4b58aa..623e9fcecbf 100644 --- a/packages/jsts/src/rules/S3800/rule.ts +++ b/packages/jsts/src/rules/S3800/rule.ts @@ -172,7 +172,9 @@ function prettyPrint(type: ts.Type, checker: ts.TypeChecker): string { } function isTypedArray(type: ts.Type, checker: ts.TypeChecker) { - return checker.typeToString(type).endsWith('Array'); + const typeAsString = checker.typeToString(type); + // Since TS 5.7 typed arrays include the type of the elements in the string, eg. Float32Array + return /.*Array(?:<[^>]*>)?$/.test(typeAsString); } function isNullLike(type: ts.Type) {