skuba 11.0.1-node16-fix-again-20250525144124 → 11.0.1-test-external-20250525154828
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/jest/transform.js
CHANGED
|
@@ -31,17 +31,11 @@ const BROKEN_MODULE_RESOLUTIONS = new Set([
|
|
|
31
31
|
*
|
|
32
32
|
* https://github.com/kulshekhar/ts-jest/issues/4198
|
|
33
33
|
*/
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
if (maybeTsConfig.moduleResolution === ModuleResolutionKind.Node16) {
|
|
40
|
-
return { tsconfig: { moduleResolution: 'Node16', module: 'Node16' } };
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
return undefined;
|
|
44
|
-
};
|
|
34
|
+
const tsconfig = BROKEN_MODULE_RESOLUTIONS.has(
|
|
35
|
+
maybeTsConfig?.options.moduleResolution,
|
|
36
|
+
)
|
|
37
|
+
? { tsconfig: { moduleResolution: 'Node' } }
|
|
38
|
+
: undefined;
|
|
45
39
|
|
|
46
40
|
/**
|
|
47
41
|
* Rewrite `ts-jest` transformations using our resolved `TS_JEST_PATH`.
|
|
@@ -57,7 +51,7 @@ module.exports.transform = Object.fromEntries(
|
|
|
57
51
|
? [
|
|
58
52
|
TS_JEST_PATH,
|
|
59
53
|
{
|
|
60
|
-
...
|
|
54
|
+
...tsconfig,
|
|
61
55
|
isolatedModules,
|
|
62
56
|
},
|
|
63
57
|
]
|
|
@@ -72,7 +66,7 @@ module.exports.transform = Object.fromEntries(
|
|
|
72
66
|
TS_JEST_PATH,
|
|
73
67
|
{
|
|
74
68
|
...value[1],
|
|
75
|
-
...
|
|
69
|
+
...tsconfig,
|
|
76
70
|
isolatedModules,
|
|
77
71
|
},
|
|
78
72
|
]
|
package/lib/cli/build/esbuild.js
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
2
|
var __defProp = Object.defineProperty;
|
|
4
3
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
4
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
5
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
6
|
var __export = (target, all) => {
|
|
9
7
|
for (var name in all)
|
|
@@ -17,14 +15,6 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
17
15
|
}
|
|
18
16
|
return to;
|
|
19
17
|
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
19
|
var esbuild_exports = {};
|
|
30
20
|
__export(esbuild_exports, {
|
|
@@ -32,7 +22,6 @@ __export(esbuild_exports, {
|
|
|
32
22
|
});
|
|
33
23
|
module.exports = __toCommonJS(esbuild_exports);
|
|
34
24
|
var import_util = require("util");
|
|
35
|
-
var import_tsconfig_paths = __toESM(require("@esbuild-plugins/tsconfig-paths"));
|
|
36
25
|
var import_esbuild = require("esbuild");
|
|
37
26
|
var import_typescript = require("typescript");
|
|
38
27
|
var import_logging = require("../../utils/logging");
|
|
@@ -67,12 +56,7 @@ const esbuild = async ({ debug }, args = process.argv.slice(2)) => {
|
|
|
67
56
|
logLevel: debug ? "debug" : "info",
|
|
68
57
|
logLimit: 0,
|
|
69
58
|
platform: compilerOptions.moduleResolution === import_typescript.ModuleResolutionKind.NodeJs ? "node" : void 0,
|
|
70
|
-
|
|
71
|
-
// evanw/esbuild#394
|
|
72
|
-
(0, import_tsconfig_paths.default)({
|
|
73
|
-
tsconfig: { baseUrl: compilerOptions.baseUrl, compilerOptions }
|
|
74
|
-
})
|
|
75
|
-
],
|
|
59
|
+
packages: bundle ? "bundle" : "external",
|
|
76
60
|
sourcemap: compilerOptions.sourceMap,
|
|
77
61
|
// TODO: as of 0.18, the esbuild CLI no longer infers the target property to
|
|
78
62
|
// avoid ambiguity where multiple `tsconfig.json`s are involved in a build.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/cli/build/esbuild.ts"],
|
|
4
|
-
"sourcesContent": ["import { inspect } from 'util';\n\nimport
|
|
5
|
-
"mappings": "
|
|
6
|
-
"names": [
|
|
4
|
+
"sourcesContent": ["import { inspect } from 'util';\n\nimport { build } from 'esbuild';\nimport { ModuleKind, ModuleResolutionKind, ScriptTarget } from 'typescript';\n\nimport { createLogger } from '../../utils/logging';\n\nimport { parseTscArgs } from './args';\nimport { readTsconfig, tsc } from './tsc';\n\ninterface EsbuildParameters {\n debug: boolean;\n}\n\nexport const esbuild = async (\n { debug }: EsbuildParameters,\n args = process.argv.slice(2),\n) => {\n const log = createLogger({ debug });\n\n const tscArgs = parseTscArgs(args);\n\n if (tscArgs.build) {\n log.err(\n 'skuba does not currently support the tsc --build flag with esbuild',\n );\n process.exitCode = 1;\n return;\n }\n\n const parsedCommandLine = readTsconfig(args, log);\n\n if (!parsedCommandLine || process.exitCode) {\n return;\n }\n\n const { fileNames: entryPoints, options: compilerOptions } =\n parsedCommandLine;\n\n log.debug(log.bold('Files'));\n entryPoints.forEach((filepath) => log.debug(filepath));\n\n log.debug(log.bold('Compiler options'));\n log.debug(inspect(compilerOptions));\n\n const start = process.hrtime.bigint();\n\n // TODO: support `bundle`, `minify`, `splitting`, `treeShaking`\n const bundle = false;\n\n await build({\n bundle,\n entryPoints,\n format: compilerOptions.module === ModuleKind.CommonJS ? 'cjs' : undefined,\n outdir: compilerOptions.outDir,\n logLevel: debug ? 'debug' : 'info',\n logLimit: 0,\n platform:\n compilerOptions.moduleResolution === ModuleResolutionKind.NodeJs\n ? 'node'\n : undefined,\n packages: bundle ? 'bundle' : 'external',\n sourcemap: compilerOptions.sourceMap,\n // TODO: as of 0.18, the esbuild CLI no longer infers the target property to\n // avoid ambiguity where multiple `tsconfig.json`s are involved in a build.\n // This would be unusual for a typical SEEK project but we can still explore\n // an explicit setting once we implement `skuba.config.ts` (#1167).\n target: compilerOptions.target\n ? ScriptTarget[compilerOptions.target].toLocaleLowerCase()\n : undefined,\n tsconfig: tscArgs.pathname,\n });\n\n const end = process.hrtime.bigint();\n\n log.plain(`Built in ${log.timing(start, end)}.`);\n\n if (compilerOptions.declaration) {\n await tsc([\n '--declaration',\n '--emitDeclarationOnly',\n ...(tscArgs.project ? ['--project', tscArgs.project] : []),\n ]);\n }\n};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAAwB;AAExB,qBAAsB;AACtB,wBAA+D;AAE/D,qBAA6B;AAE7B,kBAA6B;AAC7B,iBAAkC;AAM3B,MAAM,UAAU,OACrB,EAAE,MAAM,GACR,OAAO,QAAQ,KAAK,MAAM,CAAC,MACxB;AACH,QAAM,UAAM,6BAAa,EAAE,MAAM,CAAC;AAElC,QAAM,cAAU,0BAAa,IAAI;AAEjC,MAAI,QAAQ,OAAO;AACjB,QAAI;AAAA,MACF;AAAA,IACF;AACA,YAAQ,WAAW;AACnB;AAAA,EACF;AAEA,QAAM,wBAAoB,yBAAa,MAAM,GAAG;AAEhD,MAAI,CAAC,qBAAqB,QAAQ,UAAU;AAC1C;AAAA,EACF;AAEA,QAAM,EAAE,WAAW,aAAa,SAAS,gBAAgB,IACvD;AAEF,MAAI,MAAM,IAAI,KAAK,OAAO,CAAC;AAC3B,cAAY,QAAQ,CAAC,aAAa,IAAI,MAAM,QAAQ,CAAC;AAErD,MAAI,MAAM,IAAI,KAAK,kBAAkB,CAAC;AACtC,MAAI,UAAM,qBAAQ,eAAe,CAAC;AAElC,QAAM,QAAQ,QAAQ,OAAO,OAAO;AAGpC,QAAM,SAAS;AAEf,YAAM,sBAAM;AAAA,IACV;AAAA,IACA;AAAA,IACA,QAAQ,gBAAgB,WAAW,6BAAW,WAAW,QAAQ;AAAA,IACjE,QAAQ,gBAAgB;AAAA,IACxB,UAAU,QAAQ,UAAU;AAAA,IAC5B,UAAU;AAAA,IACV,UACE,gBAAgB,qBAAqB,uCAAqB,SACtD,SACA;AAAA,IACN,UAAU,SAAS,WAAW;AAAA,IAC9B,WAAW,gBAAgB;AAAA;AAAA;AAAA;AAAA;AAAA,IAK3B,QAAQ,gBAAgB,SACpB,+BAAa,gBAAgB,MAAM,EAAE,kBAAkB,IACvD;AAAA,IACJ,UAAU,QAAQ;AAAA,EACpB,CAAC;AAED,QAAM,MAAM,QAAQ,OAAO,OAAO;AAElC,MAAI,MAAM,YAAY,IAAI,OAAO,OAAO,GAAG,CAAC,GAAG;AAE/C,MAAI,gBAAgB,aAAa;AAC/B,cAAM,gBAAI;AAAA,MACR;AAAA,MACA;AAAA,MACA,GAAI,QAAQ,UAAU,CAAC,aAAa,QAAQ,OAAO,IAAI,CAAC;AAAA,IAC1D,CAAC;AAAA,EACH;AACF;",
|
|
6
|
+
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "skuba",
|
|
3
|
-
"version": "11.0.1-
|
|
3
|
+
"version": "11.0.1-test-external-20250525154828",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "SEEK development toolkit for backend applications and packages",
|
|
6
6
|
"homepage": "https://github.com/seek-oss/skuba#readme",
|
|
@@ -50,7 +50,6 @@
|
|
|
50
50
|
]
|
|
51
51
|
},
|
|
52
52
|
"dependencies": {
|
|
53
|
-
"@esbuild-plugins/tsconfig-paths": "^0.1.0",
|
|
54
53
|
"@eslint/migrate-config": "~1.3.8",
|
|
55
54
|
"@jest/types": "^29.0.0",
|
|
56
55
|
"@octokit/graphql": "^9.0.0",
|
|
@@ -98,7 +97,7 @@
|
|
|
98
97
|
"tsx": "^4.16.2",
|
|
99
98
|
"typescript": "~5.8.0",
|
|
100
99
|
"zod": "^3.22.4",
|
|
101
|
-
"eslint-config-skuba": "6.1.0-
|
|
100
|
+
"eslint-config-skuba": "6.1.0-test-external-20250525154828"
|
|
102
101
|
},
|
|
103
102
|
"devDependencies": {
|
|
104
103
|
"@changesets/cli": "2.29.3",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"constructs": "^10.0.17",
|
|
38
38
|
"datadog-cdk-constructs-v2": "^2.0.0",
|
|
39
39
|
"pino-pretty": "^13.0.0",
|
|
40
|
-
"skuba": "11.0.1-
|
|
40
|
+
"skuba": "11.0.1-test-external-20250525154828"
|
|
41
41
|
},
|
|
42
42
|
"packageManager": "pnpm@10.10.0",
|
|
43
43
|
"engines": {
|