Apply the ts-build-config (lib/types) convention to the new subagent packages

Master's #36 moved declaration output to lib/types (and types/exports/files
point there). The merge applied that to all pre-existing packages, but the
subagent backends introduced on this stack (subagent-inprocess, subagent-spawn,
subagent-fork) still used the old lib/ layout. Bring them onto the new
convention and add them to the single typecheck tsconfig.json references.
This commit is contained in:
Tianyi Cui
2026-06-22 14:43:51 +08:00
parent 398b4f2ccf
commit 67c7ef791f
7 changed files with 22 additions and 13 deletions

View File

@@ -5,17 +5,19 @@
"private": true, "private": true,
"type": "module", "type": "module",
"main": "lib/index.js", "main": "lib/index.js",
"types": "lib/index.d.ts", "types": "lib/types/index.d.ts",
"exports": { "exports": {
".": { ".": {
"types": "./lib/index.d.ts", "types": "./lib/types/index.d.ts",
"default": "./lib/index.js" "default": "./lib/index.js"
}, },
"./src/*": "./src/*", "./src/*": "./src/*",
"./package.json": "./package.json" "./package.json": "./package.json"
}, },
"files": [ "files": [
"lib", "lib/index.js",
"lib/types/**/*.d.ts",
"lib/types/**/*.d.ts.map",
"src" "src"
], ],
"license": "BSD-3-Clause", "license": "BSD-3-Clause",

View File

@@ -2,7 +2,7 @@
"extends": "../../../tsconfig.base.json", "extends": "../../../tsconfig.base.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "src", "rootDir": "src",
"outDir": "lib" "outDir": "lib/types"
}, },
"include": [ "include": [
"src" "src"

View File

@@ -5,17 +5,19 @@
"private": true, "private": true,
"type": "module", "type": "module",
"main": "lib/index.js", "main": "lib/index.js",
"types": "lib/index.d.ts", "types": "lib/types/index.d.ts",
"exports": { "exports": {
".": { ".": {
"types": "./lib/index.d.ts", "types": "./lib/types/index.d.ts",
"default": "./lib/index.js" "default": "./lib/index.js"
}, },
"./src/*": "./src/*", "./src/*": "./src/*",
"./package.json": "./package.json" "./package.json": "./package.json"
}, },
"files": [ "files": [
"lib", "lib/index.js",
"lib/types/**/*.d.ts",
"lib/types/**/*.d.ts.map",
"src" "src"
], ],
"license": "BSD-3-Clause", "license": "BSD-3-Clause",

View File

@@ -2,7 +2,7 @@
"extends": "../../../tsconfig.base.json", "extends": "../../../tsconfig.base.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "src", "rootDir": "src",
"outDir": "lib" "outDir": "lib/types"
}, },
"include": [ "include": [
"src" "src"

View File

@@ -5,17 +5,19 @@
"private": true, "private": true,
"type": "module", "type": "module",
"main": "lib/index.js", "main": "lib/index.js",
"types": "lib/index.d.ts", "types": "lib/types/index.d.ts",
"exports": { "exports": {
".": { ".": {
"types": "./lib/index.d.ts", "types": "./lib/types/index.d.ts",
"default": "./lib/index.js" "default": "./lib/index.js"
}, },
"./src/*": "./src/*", "./src/*": "./src/*",
"./package.json": "./package.json" "./package.json": "./package.json"
}, },
"files": [ "files": [
"lib", "lib/index.js",
"lib/types/**/*.d.ts",
"lib/types/**/*.d.ts.map",
"src" "src"
], ],
"license": "BSD-3-Clause", "license": "BSD-3-Clause",

View File

@@ -2,7 +2,7 @@
"extends": "../../../tsconfig.base.json", "extends": "../../../tsconfig.base.json",
"compilerOptions": { "compilerOptions": {
"rootDir": "src", "rootDir": "src",
"outDir": "lib" "outDir": "lib/types"
}, },
"include": [ "include": [
"src" "src"

View File

@@ -45,6 +45,9 @@
{ "path": "./packages/support/llm-replay" }, { "path": "./packages/support/llm-replay" },
{ "path": "./packages/subagent/subagent" }, { "path": "./packages/subagent/subagent" },
{ "path": "./packages/support/subagent-mock" }, { "path": "./packages/support/subagent-mock" },
{ "path": "./packages/subagent/tool-subagent" } { "path": "./packages/subagent/tool-subagent" },
{ "path": "./packages/subagent/subagent-inprocess" },
{ "path": "./packages/subagent/subagent-spawn" },
{ "path": "./packages/subagent/subagent-fork" }
] ]
} }