From 351410677fc8b94d0380bf7be015b939947941d2 Mon Sep 17 00:00:00 2001 From: Alexander Skvortsov Date: Wed, 9 Feb 2022 18:13:24 -0500 Subject: [PATCH] fix: refer to bundled dist-typing types instead of src ones This ensures that extensions referring to core's built dist typings don't try to pull from core's src code. --- framework/core/js/package.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/framework/core/js/package.json b/framework/core/js/package.json index a2d6a6186..66d087445 100644 --- a/framework/core/js/package.json +++ b/framework/core/js/package.json @@ -43,7 +43,8 @@ "format": "prettier --write src", "format-check": "prettier --check src", "clean-typings": "npx rimraf dist-typings && mkdir dist-typings", - "build-typings": "yarn run clean-typings && tsc && [ -e src/@types ] && cp -r src/@types dist-typings/@types", + "build-typings": "yarn run clean-typings && [ -e src/@types ] && cp -r src/@types dist-typings/@types && tsc && yarn run post-build-typings", + "post-build-typings": "find dist-typings -type f -name '*.d.ts' -print0 | xargs -0 sed -i 's,../src/@types,@types,g'", "check-typings": "tsc --noEmit --emitDeclarationOnly false", "check-typings-coverage": "typescript-coverage-report" },