refactor: 重构项目结构,将 tracer 模块提取为独立子包

- 将 tracer 相关代码移动到 tracers.ts 子目录中
- 新增类型定义文件,统一管理命令类型
- 实现上下文管理机制,集中处理 tracer 命令
- 更新构建配置和依赖管理
- 移除旧的根目录文件,保持代码结构清晰
This commit is contained in:
2026-02-04 13:45:17 +08:00
parent c90f4a0244
commit a3bbd5638a
21 changed files with 468 additions and 53 deletions

29
tracers.ts/tsconfig.json Normal file
View File

@@ -0,0 +1,29 @@
{
"compilerOptions": {
// Environment setup & latest features
"lib": ["ESNext"],
"target": "ESNext",
"module": "Preserve",
"moduleDetection": "force",
"jsx": "react-jsx",
"allowJs": true,
// Bundler mode
"moduleResolution": "bundler",
"allowImportingTsExtensions": true,
"verbatimModuleSyntax": true,
"noEmit": true,
// Best practices
"strict": true,
"skipLibCheck": true,
"noFallthroughCasesInSwitch": true,
"noUncheckedIndexedAccess": true,
"noImplicitOverride": true,
// Some stricter flags (disabled by default)
"noUnusedLocals": false,
"noUnusedParameters": false,
"noPropertyAccessFromIndexSignature": false
}
}