From c68d468e016240646e977a2b1356786168e6d63a Mon Sep 17 00:00:00 2001 From: AllanZhengYP Date: Thu, 29 Jun 2023 14:01:08 -0700 Subject: [PATCH] fix(core): add @types/node-fetch to runtime dependency (#11560) The isomorphic-unfetch dependency re-exports artifacts from node-fetch package in its .d.ts file. However, the node-fetch package does not contain any .d.ts file with itself. So the exported artifacts can not be resolved by tsc. It's not an issue before possibly because the client-s3 contains transitive runtime dependency of @types/node-fetch. Since it's removed now, we are encountered with this error. Adding the dependency to runtime instead of dev or peer deps to prevent brokage for customers --- packages/core/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/core/package.json b/packages/core/package.json index 28d0a787676..f37298ac589 100644 --- a/packages/core/package.json +++ b/packages/core/package.json @@ -69,6 +69,7 @@ "@aws-sdk/client-cloudwatch-logs": "3.6.1", "@aws-sdk/types": "3.6.1", "@aws-sdk/util-hex-encoding": "3.6.1", + "@types/node-fetch": "2.6.4", "isomorphic-unfetch": "^3.0.0", "react-native-url-polyfill": "^1.3.0", "tslib": "^1.8.0",