forked from claude-did-this/claude-hub
## Overview Establishes comprehensive TypeScript infrastructure and tooling for the claude-github-webhook project as specified in issue #101. ## Dependencies Added - Core TypeScript: typescript, @types/node, @types/express, @types/body-parser - Development: ts-node for dev execution - ESLint: @typescript-eslint/parser, @typescript-eslint/eslint-plugin - Testing: ts-jest, babel-jest for Jest TypeScript support ## Configuration Files - tsconfig.json: Strict TypeScript config targeting ES2022/CommonJS - eslint.config.js: Updated with TypeScript support and strict rules - jest.config.js: Configured for both .js and .ts test files - babel.config.js: Babel configuration for JavaScript transformation ## Build Scripts - npm run build: Compile TypeScript to dist/ - npm run build⌚ Watch mode compilation - npm run typecheck: Type checking without compilation - npm run clean: Clean build artifacts - npm run dev: Development with ts-node - npm run dev⌚ Development with nodemon + ts-node ## Infrastructure Verified ✅ TypeScript compilation works ✅ ESLint supports TypeScript files ✅ Jest runs tests with TypeScript support ✅ All existing tests pass (67 tests, 2 skipped) ✅ Docker build process updated for TypeScript ## Documentation - CLAUDE.md updated with TypeScript build commands and architecture - Migration strategy documented (Phase 1: Infrastructure, Phase 2: Code conversion) - TypeScript coding guidelines added ## Backward Compatibility - Existing JavaScript files continue to work during transition - Support for both .js and .ts files in tests and linting - No breaking changes to existing functionality 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
48 lines
1.1 KiB
JSON
48 lines
1.1 KiB
JSON
{
|
|
"compilerOptions": {
|
|
"target": "ES2022",
|
|
"module": "CommonJS",
|
|
"lib": ["ES2022"],
|
|
"outDir": "./dist",
|
|
"rootDir": "./src",
|
|
"strict": true,
|
|
"esModuleInterop": true,
|
|
"skipLibCheck": true,
|
|
"forceConsistentCasingInFileNames": true,
|
|
"resolveJsonModule": true,
|
|
"allowSyntheticDefaultImports": true,
|
|
"sourceMap": true,
|
|
"declaration": true,
|
|
"declarationMap": true,
|
|
"removeComments": false,
|
|
"noImplicitAny": true,
|
|
"noImplicitReturns": true,
|
|
"noImplicitThis": true,
|
|
"noUnusedLocals": true,
|
|
"noUnusedParameters": true,
|
|
"exactOptionalPropertyTypes": true,
|
|
"noImplicitOverride": true,
|
|
"noPropertyAccessFromIndexSignature": true,
|
|
"noUncheckedIndexedAccess": true,
|
|
"allowUnusedLabels": false,
|
|
"allowUnreachableCode": false,
|
|
"noFallthroughCasesInSwitch": true,
|
|
"types": ["node", "jest"]
|
|
},
|
|
"include": [
|
|
"src/**/*",
|
|
"test/**/*"
|
|
],
|
|
"exclude": [
|
|
"node_modules",
|
|
"dist",
|
|
"coverage",
|
|
"test-results"
|
|
],
|
|
"ts-node": {
|
|
"files": true,
|
|
"compilerOptions": {
|
|
"module": "CommonJS"
|
|
}
|
|
}
|
|
} |