From 3238bbc9f462081765014a6046fdec03a391005e Mon Sep 17 00:00:00 2001 From: Alex Hunt Date: Thu, 13 Apr 2023 05:21:17 -0700 Subject: [PATCH] Align types location for metro-source-map entry point Summary: Follow-up to D44509764. `metro-source-map`'s entry point is `src/source-map.js`. Changelog: **[Types]** Fix TypeScript types entry point for metro-source-map Reviewed By: jacdebug Differential Revision: D44953195 fbshipit-source-id: 82aafbe443f51ae1f1f2dffe7d4ce4ea206fa00f --- .../metro-source-map/types/{index.d.ts => source-map.d.ts} | 0 tsconfig.json | 6 +++++- 2 files changed, 5 insertions(+), 1 deletion(-) rename packages/metro-source-map/types/{index.d.ts => source-map.d.ts} (100%) diff --git a/packages/metro-source-map/types/index.d.ts b/packages/metro-source-map/types/source-map.d.ts similarity index 100% rename from packages/metro-source-map/types/index.d.ts rename to packages/metro-source-map/types/source-map.d.ts diff --git a/tsconfig.json b/tsconfig.json index 3073b0f31f..f5f62b4c9c 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -8,7 +8,11 @@ "paths": { "metro": ["./packages/metro/types"], "metro/src/*": ["./packages/metro/types/*"], - "metro-*": ["./packages/metro-*/types"] + "metro-*": ["./packages/metro-*/types"], + // Mappings for main entry points which are not "src/index.js". Required + // only for this tsconfig - external consumers will read the "main" field + // and find the adjacent typedef file. + "metro-source-map": ["./packages/metro-source-map/types/source-map.d.ts"] } } }