diff --git a/javascript/package-lock.json b/javascript/package-lock.json index d38ebe51..e7ee771e 100644 --- a/javascript/package-lock.json +++ b/javascript/package-lock.json @@ -25,14 +25,14 @@ "@types/chai-xml": "^0.3.6", "@types/luxon": "^3.4.2", "@types/mocha": "^10.0.6", - "@types/node": "24.12.4", + "@types/node": "^22", "chai": "^6.0.0", "chai-almost": "^1.0.1", "chai-xml": "^0.4.1", "globby": "^16.0.0", "mocha": "^11.0.0", "ts-node": "^10.9.1", - "typescript": "5.9.3" + "typescript": "6.0.3" }, "peerDependencies": { "@cucumber/messages": "*" @@ -461,13 +461,13 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "24.12.4", - "resolved": "https://registry.npmjs.org/@types/node/-/node-24.12.4.tgz", - "integrity": "sha512-GUUEShf+PBCGW2KaXwcIt3Yk+e3pkKwWKb9GSyM9WQVE+ep2jzmHdGsHzu4wgcZy5fN9FBdVzjpBQsYlpfpgLA==", + "version": "22.19.19", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.19.19.tgz", + "integrity": "sha512-dyh/xO2Fh5bYrfWaaqGrRQQGkNdmYw6AmaAUvYeUMNTWQtvb796ikLdmTchRmOlOiIJ1TDXfWgVx1QkUlQ6Hew==", "dev": true, "license": "MIT", "dependencies": { - "undici-types": "~7.16.0" + "undici-types": "~6.21.0" } }, "node_modules/acorn": { @@ -1885,9 +1885,9 @@ } }, "node_modules/typescript": { - "version": "5.9.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", - "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-6.0.3.tgz", + "integrity": "sha512-y2TvuxSZPDyQakkFRPZHKFm+KKVqIisdg9/CZwm9ftvKXLP8NRWj38/ODjNbr43SsoXqNuAisEf1GdCxqWcdBw==", "dev": true, "license": "Apache-2.0", "bin": { @@ -1899,9 +1899,9 @@ } }, "node_modules/undici-types": { - "version": "7.16.0", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-7.16.0.tgz", - "integrity": "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw==", + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", "dev": true, "license": "MIT" }, diff --git a/javascript/package.json b/javascript/package.json index 0a965509..509c58ba 100644 --- a/javascript/package.json +++ b/javascript/package.json @@ -13,12 +13,12 @@ "author": "David Goss", "license": "MIT", "scripts": { - "build": "tsc --build tsconfig.build.json", + "build": "tsc -p tsconfig.build.json", "clean": "rm -rf dist", "fix": "biome check --fix --error-on-warnings", "lint": "biome check --error-on-warnings", "test": "mocha \"src/**/*.spec.ts\"", - "prepublishOnly": "tsc --build tsconfig.build.json" + "prepublishOnly": "npm run build" }, "dependencies": { "@cucumber/query": "^15.0.1", @@ -40,13 +40,13 @@ "@types/chai-xml": "^0.3.6", "@types/luxon": "^3.4.2", "@types/mocha": "^10.0.6", - "@types/node": "24.12.4", + "@types/node": "^22", "chai": "^6.0.0", "chai-almost": "^1.0.1", "chai-xml": "^0.4.1", "globby": "^16.0.0", "mocha": "^11.0.0", "ts-node": "^10.9.1", - "typescript": "5.9.3" + "typescript": "6.0.3" } } diff --git a/javascript/tsconfig.build.json b/javascript/tsconfig.build.json index 74cb3c9a..851de8ae 100644 --- a/javascript/tsconfig.build.json +++ b/javascript/tsconfig.build.json @@ -1,5 +1,9 @@ { "extends": "./tsconfig.json", "include": ["src"], - "exclude": ["src/**/*.spec.*"] + "exclude": ["src/**/*.spec.*"], + "compilerOptions": { + "rootDir": "src", + "outDir": "dist" + } } diff --git a/javascript/tsconfig.json b/javascript/tsconfig.json index b2f1a3ad..26339602 100644 --- a/javascript/tsconfig.json +++ b/javascript/tsconfig.json @@ -2,10 +2,13 @@ "extends": "@tsconfig/recommended/tsconfig.json", "include": ["src"], "compilerOptions": { - "lib": ["dom", "es2023"], - "target": "es2022", + "lib": ["es2024"], + "target": "es2024", + "module": "NodeNext", + "moduleResolution": "NodeNext", + "types": ["node", "mocha", "chai"], "declaration": true, - "outDir": "dist", - "inlineSourceMap": true + "inlineSourceMap": true, + "inlineSources": true } }