@storm-software/workspace-tools 1.11.0 → 1.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/index.js +44 -20
- package/meta.json +1 -1
- package/package.json +1 -1
- package/src/executors/tsup/executor.js +57 -27
- package/src/executors/tsup/get-config.js +44 -20
- package/src/executors/tsup/schema.d.ts +1 -0
- package/src/executors/tsup/schema.json +7 -1
package/package.json
CHANGED
|
@@ -408390,9 +408390,9 @@ var require_brace_expansion2 = __commonJS({
|
|
|
408390
408390
|
}
|
|
408391
408391
|
});
|
|
408392
408392
|
|
|
408393
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
408393
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-EPAEWGCP.js
|
|
408394
408394
|
var require_chunk_EPAEWGCP = __commonJS({
|
|
408395
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
408395
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-EPAEWGCP.js"(exports) {
|
|
408396
408396
|
"use strict";
|
|
408397
408397
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
408398
408398
|
var version = "8.0.0";
|
|
@@ -410039,9 +410039,9 @@ var require_resolve_from = __commonJS({
|
|
|
410039
410039
|
}
|
|
410040
410040
|
});
|
|
410041
410041
|
|
|
410042
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
410042
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-GQ77QZBO.js
|
|
410043
410043
|
var require_chunk_GQ77QZBO = __commonJS({
|
|
410044
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
410044
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-GQ77QZBO.js"(exports) {
|
|
410045
410045
|
"use strict";
|
|
410046
410046
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
410047
410047
|
function _interopRequireDefault(obj) {
|
|
@@ -410319,9 +410319,9 @@ var require_chunk_GQ77QZBO = __commonJS({
|
|
|
410319
410319
|
}
|
|
410320
410320
|
});
|
|
410321
410321
|
|
|
410322
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
410322
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-UIX4URMV.js
|
|
410323
410323
|
var require_chunk_UIX4URMV = __commonJS({
|
|
410324
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
410324
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-UIX4URMV.js"(exports) {
|
|
410325
410325
|
"use strict";
|
|
410326
410326
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
410327
410327
|
function _interopRequireWildcard(obj) {
|
|
@@ -411255,9 +411255,9 @@ var require_dist2 = __commonJS({
|
|
|
411255
411255
|
}
|
|
411256
411256
|
});
|
|
411257
411257
|
|
|
411258
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
411258
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-7G76EW2R.js
|
|
411259
411259
|
var require_chunk_7G76EW2R = __commonJS({
|
|
411260
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
411260
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-7G76EW2R.js"(exports) {
|
|
411261
411261
|
"use strict";
|
|
411262
411262
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
411263
411263
|
function _interopRequireDefault(obj) {
|
|
@@ -465063,9 +465063,9 @@ var require_chokidar = __commonJS({
|
|
|
465063
465063
|
}
|
|
465064
465064
|
});
|
|
465065
465065
|
|
|
465066
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
465066
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/index.js
|
|
465067
465067
|
var require_dist5 = __commonJS({
|
|
465068
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
465068
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/index.js"(exports) {
|
|
465069
465069
|
"use strict";
|
|
465070
465070
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
465071
465071
|
function _interopRequireDefault(obj) {
|
|
@@ -467294,13 +467294,13 @@ var require_dist5 = __commonJS({
|
|
|
467294
467294
|
}
|
|
467295
467295
|
return program.getRootFileNames().flatMap(extractExports);
|
|
467296
467296
|
}
|
|
467297
|
-
function emitDtsFiles(program, host) {
|
|
467297
|
+
function emitDtsFiles(program, host, options) {
|
|
467298
467298
|
let fileMapping = /* @__PURE__ */ new Map();
|
|
467299
467299
|
let writeFile2 = (fileName, text, writeByteOrderMark, onError, sourceFiles, data) => {
|
|
467300
467300
|
const sourceFile = _optionalChain([sourceFiles, "optionalAccess", (_14) => _14[0]]);
|
|
467301
467301
|
let sourceFileName = _optionalChain([sourceFile, "optionalAccess", (_15) => _15.fileName]);
|
|
467302
467302
|
if (sourceFileName && !fileName.endsWith(".map")) {
|
|
467303
|
-
const cwd = program.getCurrentDirectory();
|
|
467303
|
+
const cwd = options.workspaceRoot ? options.workspaceRoot : program.getCurrentDirectory();
|
|
467304
467304
|
fileMapping.set(
|
|
467305
467305
|
_chunkGQ77QZBOjs.toAbsolutePath.call(void 0, sourceFileName, cwd),
|
|
467306
467306
|
_chunkGQ77QZBOjs.toAbsolutePath.call(void 0, fileName, cwd)
|
|
@@ -467315,6 +467315,7 @@ var require_dist5 = __commonJS({
|
|
|
467315
467315
|
data
|
|
467316
467316
|
);
|
|
467317
467317
|
};
|
|
467318
|
+
logger.info("tsc", "Emitting DTS files");
|
|
467318
467319
|
let emitResult = program.emit(void 0, writeFile2, void 0, true);
|
|
467319
467320
|
let diagnostics = _typescript2.default.getPreEmitDiagnostics(program).concat(emitResult.diagnostics);
|
|
467320
467321
|
let diagnosticMessages = [];
|
|
@@ -467367,14 +467368,15 @@ var require_dist5 = __commonJS({
|
|
|
467367
467368
|
}
|
|
467368
467369
|
logger.info("tsc", "Getting temporary declaration directory");
|
|
467369
467370
|
let declarationDir = _chunkGQ77QZBOjs.ensureTempDeclarationDir.call(void 0, options);
|
|
467370
|
-
logger.info("tsc", declarationDir);
|
|
467371
|
+
logger.info("tsc", `Temporary declaration directory: ${declarationDir}`);
|
|
467372
|
+
logger.info("tsc", "Raw tsconfig.json: ");
|
|
467373
|
+
logger.info("tsc", rawTsconfig);
|
|
467371
467374
|
logger.info("tsc", "Parsing tsconfig.json");
|
|
467372
467375
|
let parsedTsconfig = _typescript2.default.parseJsonConfigFileContent(
|
|
467373
467376
|
{
|
|
467374
467377
|
...rawTsconfig.data,
|
|
467375
467378
|
compilerOptions: {
|
|
467376
467379
|
...rawTsconfig.data.compilerOptions,
|
|
467377
|
-
...compilerOptions,
|
|
467378
467380
|
// Enable declaration emit and disable javascript emit
|
|
467379
467381
|
outDir: options.outDir,
|
|
467380
467382
|
noEmit: false,
|
|
@@ -467384,22 +467386,44 @@ var require_dist5 = __commonJS({
|
|
|
467384
467386
|
emitDeclarationOnly: true
|
|
467385
467387
|
},
|
|
467386
467388
|
include: [
|
|
467387
|
-
...rawTsconfig.data.
|
|
467388
|
-
|
|
467389
|
+
...rawTsconfig.data.include?.map?.((include) => _path.join(
|
|
467390
|
+
options.projectRoot,
|
|
467391
|
+
include
|
|
467392
|
+
)) ?? {}
|
|
467393
|
+
],
|
|
467394
|
+
exclude: [
|
|
467395
|
+
...rawTsconfig.data.exclude?.map?.((exclude) => _path.join(
|
|
467396
|
+
options.projectRoot,
|
|
467397
|
+
exclude
|
|
467398
|
+
)) ?? {}
|
|
467389
467399
|
]
|
|
467390
467400
|
},
|
|
467391
467401
|
_typescript2.default.sys,
|
|
467392
467402
|
options.workspaceRoot ? options.workspaceRoot : tsconfig ? _path.dirname.call(void 0, tsconfig) : options.projectRoot
|
|
467393
467403
|
);
|
|
467394
467404
|
logger.info("tsc", parsedTsconfig);
|
|
467395
|
-
let
|
|
467405
|
+
let tsOptions = parsedTsconfig.options;
|
|
467406
|
+
if (parsedTsconfig.raw.include) {
|
|
467407
|
+
tsOptions.include = [
|
|
467408
|
+
...tsOptions.include ?? {},
|
|
467409
|
+
...parsedTsconfig.raw.include
|
|
467410
|
+
];
|
|
467411
|
+
}
|
|
467412
|
+
if (parsedTsconfig.raw.exclude) {
|
|
467413
|
+
tsOptions.exclude = [
|
|
467414
|
+
...tsOptions.exclude ?? {},
|
|
467415
|
+
...parsedTsconfig.raw.exclude
|
|
467416
|
+
];
|
|
467417
|
+
}
|
|
467418
|
+
let host = _typescript2.default.createCompilerHost(tsOptions);
|
|
467396
467419
|
let program = _typescript2.default.createProgram(
|
|
467397
467420
|
parsedTsconfig.fileNames,
|
|
467398
|
-
|
|
467421
|
+
tsOptions,
|
|
467399
467422
|
host
|
|
467400
467423
|
);
|
|
467401
|
-
logger.info("tsc", "Emitting DTS files");
|
|
467402
|
-
|
|
467424
|
+
logger.info("tsc", "Emitting DTS files with the following options: ");
|
|
467425
|
+
logger.info("tsc", tsOptions);
|
|
467426
|
+
let fileMapping = emitDtsFiles(program, host, options);
|
|
467403
467427
|
logger.info("tsc", fileMapping);
|
|
467404
467428
|
return getExports(options, program, fileMapping);
|
|
467405
467429
|
}
|
|
@@ -474499,6 +474523,7 @@ async function runExecutor(options, context) {
|
|
|
474499
474523
|
options.external ??= [];
|
|
474500
474524
|
options.additionalEntryPoints ??= [];
|
|
474501
474525
|
options.assets ??= [];
|
|
474526
|
+
options.includeSrc ??= true;
|
|
474502
474527
|
options.clean ??= true;
|
|
474503
474528
|
options.bundle ??= true;
|
|
474504
474529
|
options.debug ??= false;
|
|
@@ -474542,11 +474567,13 @@ ${Object.keys(options).map(
|
|
|
474542
474567
|
glob: "LICENSE",
|
|
474543
474568
|
output: "."
|
|
474544
474569
|
});
|
|
474545
|
-
|
|
474546
|
-
|
|
474547
|
-
|
|
474548
|
-
|
|
474549
|
-
|
|
474570
|
+
if (options.includeSrc) {
|
|
474571
|
+
assets.push({
|
|
474572
|
+
input: sourceRoot,
|
|
474573
|
+
glob: "**/{*.d.ts,*.ts,*.tsx}",
|
|
474574
|
+
output: "src/"
|
|
474575
|
+
});
|
|
474576
|
+
}
|
|
474550
474577
|
const result = await (0, import_js.copyAssets)(
|
|
474551
474578
|
{ assets, watch: options.watch, outputPath },
|
|
474552
474579
|
context
|
|
@@ -474634,7 +474661,10 @@ ${externalDependencies.map((dep) => {
|
|
|
474634
474661
|
packageJson.module ??= "dist/legacy/index.js";
|
|
474635
474662
|
options.platform && options.platform !== "node" && (packageJson.browser ??= "dist/modern/index.global.js");
|
|
474636
474663
|
packageJson.sideEffects ??= false;
|
|
474637
|
-
packageJson.files ??= ["dist"
|
|
474664
|
+
packageJson.files ??= ["dist"];
|
|
474665
|
+
if (options.includeSrc && !packageJson.files.includes("src")) {
|
|
474666
|
+
packageJson.files.push("src");
|
|
474667
|
+
}
|
|
474638
474668
|
packageJson.publishConfig ??= {
|
|
474639
474669
|
access: "public"
|
|
474640
474670
|
};
|
|
@@ -474666,7 +474696,7 @@ ${externalDependencies.map((dep) => {
|
|
|
474666
474696
|
endOfLine: "lf"
|
|
474667
474697
|
})
|
|
474668
474698
|
);
|
|
474669
|
-
if (options.banner) {
|
|
474699
|
+
if (options.banner && options.includeSrc) {
|
|
474670
474700
|
const files = globSync([
|
|
474671
474701
|
(0, import_path3.join)(context.root, outputPath, "src/**/*.ts"),
|
|
474672
474702
|
(0, import_path3.join)(context.root, outputPath, "src/**/*.tsx"),
|
|
@@ -240,9 +240,9 @@ var require_brace_expansion = __commonJS({
|
|
|
240
240
|
}
|
|
241
241
|
});
|
|
242
242
|
|
|
243
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
243
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-EPAEWGCP.js
|
|
244
244
|
var require_chunk_EPAEWGCP = __commonJS({
|
|
245
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
245
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-EPAEWGCP.js"(exports) {
|
|
246
246
|
"use strict";
|
|
247
247
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
248
248
|
var version = "8.0.0";
|
|
@@ -6549,9 +6549,9 @@ var require_resolve_from = __commonJS({
|
|
|
6549
6549
|
}
|
|
6550
6550
|
});
|
|
6551
6551
|
|
|
6552
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
6552
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-GQ77QZBO.js
|
|
6553
6553
|
var require_chunk_GQ77QZBO = __commonJS({
|
|
6554
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
6554
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-GQ77QZBO.js"(exports) {
|
|
6555
6555
|
"use strict";
|
|
6556
6556
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6557
6557
|
function _interopRequireDefault(obj) {
|
|
@@ -6829,9 +6829,9 @@ var require_chunk_GQ77QZBO = __commonJS({
|
|
|
6829
6829
|
}
|
|
6830
6830
|
});
|
|
6831
6831
|
|
|
6832
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
6832
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-UIX4URMV.js
|
|
6833
6833
|
var require_chunk_UIX4URMV = __commonJS({
|
|
6834
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
6834
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-UIX4URMV.js"(exports) {
|
|
6835
6835
|
"use strict";
|
|
6836
6836
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6837
6837
|
function _interopRequireWildcard(obj) {
|
|
@@ -7765,9 +7765,9 @@ var require_dist2 = __commonJS({
|
|
|
7765
7765
|
}
|
|
7766
7766
|
});
|
|
7767
7767
|
|
|
7768
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
7768
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-7G76EW2R.js
|
|
7769
7769
|
var require_chunk_7G76EW2R = __commonJS({
|
|
7770
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
7770
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/chunk-7G76EW2R.js"(exports) {
|
|
7771
7771
|
"use strict";
|
|
7772
7772
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7773
7773
|
function _interopRequireDefault(obj) {
|
|
@@ -249450,9 +249450,9 @@ var require_chokidar = __commonJS({
|
|
|
249450
249450
|
}
|
|
249451
249451
|
});
|
|
249452
249452
|
|
|
249453
|
-
// node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
249453
|
+
// node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/index.js
|
|
249454
249454
|
var require_dist5 = __commonJS({
|
|
249455
|
-
"node_modules/.pnpm/tsup@8.0.0_patch_hash=
|
|
249455
|
+
"node_modules/.pnpm/tsup@8.0.0_patch_hash=mrgqjamzzutjuul4r5hsd4fzdm_@microsoft+api-extractor@7.38.3_@swc+core@1._2vsze3mdmvixjcbj6wizoiwkru/node_modules/tsup/dist/index.js"(exports) {
|
|
249456
249456
|
"use strict";
|
|
249457
249457
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
249458
249458
|
function _interopRequireDefault(obj) {
|
|
@@ -251681,13 +251681,13 @@ var require_dist5 = __commonJS({
|
|
|
251681
251681
|
}
|
|
251682
251682
|
return program.getRootFileNames().flatMap(extractExports);
|
|
251683
251683
|
}
|
|
251684
|
-
function emitDtsFiles(program, host) {
|
|
251684
|
+
function emitDtsFiles(program, host, options) {
|
|
251685
251685
|
let fileMapping = /* @__PURE__ */ new Map();
|
|
251686
251686
|
let writeFile = (fileName, text, writeByteOrderMark, onError, sourceFiles, data) => {
|
|
251687
251687
|
const sourceFile = _optionalChain([sourceFiles, "optionalAccess", (_14) => _14[0]]);
|
|
251688
251688
|
let sourceFileName = _optionalChain([sourceFile, "optionalAccess", (_15) => _15.fileName]);
|
|
251689
251689
|
if (sourceFileName && !fileName.endsWith(".map")) {
|
|
251690
|
-
const cwd = program.getCurrentDirectory();
|
|
251690
|
+
const cwd = options.workspaceRoot ? options.workspaceRoot : program.getCurrentDirectory();
|
|
251691
251691
|
fileMapping.set(
|
|
251692
251692
|
_chunkGQ77QZBOjs.toAbsolutePath.call(void 0, sourceFileName, cwd),
|
|
251693
251693
|
_chunkGQ77QZBOjs.toAbsolutePath.call(void 0, fileName, cwd)
|
|
@@ -251702,6 +251702,7 @@ var require_dist5 = __commonJS({
|
|
|
251702
251702
|
data
|
|
251703
251703
|
);
|
|
251704
251704
|
};
|
|
251705
|
+
logger.info("tsc", "Emitting DTS files");
|
|
251705
251706
|
let emitResult = program.emit(void 0, writeFile, void 0, true);
|
|
251706
251707
|
let diagnostics = _typescript2.default.getPreEmitDiagnostics(program).concat(emitResult.diagnostics);
|
|
251707
251708
|
let diagnosticMessages = [];
|
|
@@ -251754,14 +251755,15 @@ var require_dist5 = __commonJS({
|
|
|
251754
251755
|
}
|
|
251755
251756
|
logger.info("tsc", "Getting temporary declaration directory");
|
|
251756
251757
|
let declarationDir = _chunkGQ77QZBOjs.ensureTempDeclarationDir.call(void 0, options);
|
|
251757
|
-
logger.info("tsc", declarationDir);
|
|
251758
|
+
logger.info("tsc", `Temporary declaration directory: ${declarationDir}`);
|
|
251759
|
+
logger.info("tsc", "Raw tsconfig.json: ");
|
|
251760
|
+
logger.info("tsc", rawTsconfig);
|
|
251758
251761
|
logger.info("tsc", "Parsing tsconfig.json");
|
|
251759
251762
|
let parsedTsconfig = _typescript2.default.parseJsonConfigFileContent(
|
|
251760
251763
|
{
|
|
251761
251764
|
...rawTsconfig.data,
|
|
251762
251765
|
compilerOptions: {
|
|
251763
251766
|
...rawTsconfig.data.compilerOptions,
|
|
251764
|
-
...compilerOptions,
|
|
251765
251767
|
// Enable declaration emit and disable javascript emit
|
|
251766
251768
|
outDir: options.outDir,
|
|
251767
251769
|
noEmit: false,
|
|
@@ -251771,22 +251773,44 @@ var require_dist5 = __commonJS({
|
|
|
251771
251773
|
emitDeclarationOnly: true
|
|
251772
251774
|
},
|
|
251773
251775
|
include: [
|
|
251774
|
-
...rawTsconfig.data.
|
|
251775
|
-
|
|
251776
|
+
...rawTsconfig.data.include?.map?.((include) => _path.join(
|
|
251777
|
+
options.projectRoot,
|
|
251778
|
+
include
|
|
251779
|
+
)) ?? {}
|
|
251780
|
+
],
|
|
251781
|
+
exclude: [
|
|
251782
|
+
...rawTsconfig.data.exclude?.map?.((exclude) => _path.join(
|
|
251783
|
+
options.projectRoot,
|
|
251784
|
+
exclude
|
|
251785
|
+
)) ?? {}
|
|
251776
251786
|
]
|
|
251777
251787
|
},
|
|
251778
251788
|
_typescript2.default.sys,
|
|
251779
251789
|
options.workspaceRoot ? options.workspaceRoot : tsconfig ? _path.dirname.call(void 0, tsconfig) : options.projectRoot
|
|
251780
251790
|
);
|
|
251781
251791
|
logger.info("tsc", parsedTsconfig);
|
|
251782
|
-
let
|
|
251792
|
+
let tsOptions = parsedTsconfig.options;
|
|
251793
|
+
if (parsedTsconfig.raw.include) {
|
|
251794
|
+
tsOptions.include = [
|
|
251795
|
+
...tsOptions.include ?? {},
|
|
251796
|
+
...parsedTsconfig.raw.include
|
|
251797
|
+
];
|
|
251798
|
+
}
|
|
251799
|
+
if (parsedTsconfig.raw.exclude) {
|
|
251800
|
+
tsOptions.exclude = [
|
|
251801
|
+
...tsOptions.exclude ?? {},
|
|
251802
|
+
...parsedTsconfig.raw.exclude
|
|
251803
|
+
];
|
|
251804
|
+
}
|
|
251805
|
+
let host = _typescript2.default.createCompilerHost(tsOptions);
|
|
251783
251806
|
let program = _typescript2.default.createProgram(
|
|
251784
251807
|
parsedTsconfig.fileNames,
|
|
251785
|
-
|
|
251808
|
+
tsOptions,
|
|
251786
251809
|
host
|
|
251787
251810
|
);
|
|
251788
|
-
logger.info("tsc", "Emitting DTS files");
|
|
251789
|
-
|
|
251811
|
+
logger.info("tsc", "Emitting DTS files with the following options: ");
|
|
251812
|
+
logger.info("tsc", tsOptions);
|
|
251813
|
+
let fileMapping = emitDtsFiles(program, host, options);
|
|
251790
251814
|
logger.info("tsc", fileMapping);
|
|
251791
251815
|
return getExports(options, program, fileMapping);
|
|
251792
251816
|
}
|
|
@@ -8,7 +8,8 @@
|
|
|
8
8
|
"properties": {
|
|
9
9
|
"entry": {
|
|
10
10
|
"type": "string",
|
|
11
|
-
"description": "The path to the entry file, relative to project."
|
|
11
|
+
"description": "The path to the entry file, relative to project.",
|
|
12
|
+
"alias": "main"
|
|
12
13
|
},
|
|
13
14
|
"outputPath": {
|
|
14
15
|
"type": "string",
|
|
@@ -64,6 +65,11 @@
|
|
|
64
65
|
"alias": "deleteOutputPath",
|
|
65
66
|
"default": true
|
|
66
67
|
},
|
|
68
|
+
"includeSrc": {
|
|
69
|
+
"type": "boolean",
|
|
70
|
+
"description": "Should the source files be added to the distribution folder in an `src` directory.",
|
|
71
|
+
"default": true
|
|
72
|
+
},
|
|
67
73
|
"debug": {
|
|
68
74
|
"type": "boolean",
|
|
69
75
|
"description": "Should output be unminified with source mappings.",
|