feat: add TypeScript-based OpenAPI Clean Architecture generator
- Introduced a new TypeScript file (generate.ts) for generating Angular code with Clean Architecture from OpenAPI/Swagger specifications. - Implemented a CLI using Commander.js for user input and options. - Added functions for analyzing Swagger files, generating code, organizing files, and creating a report. - Integrated Mustache templates for generating models, repositories, use cases, and mappers. - Created a build process with TypeScript and updated package.json to include build scripts and dependencies. - Added TypeScript configuration (tsconfig.json) for compiling the TypeScript code. - Updated the main entry point in package.json to point to the compiled JavaScript file in the dist directory.
This commit is contained in:
17
package.json
17
package.json
@@ -2,12 +2,15 @@
|
||||
"name": "openapi-clean-arch-generator",
|
||||
"version": "1.0.0",
|
||||
"description": "Generador de código Angular con Clean Architecture desde OpenAPI/Swagger",
|
||||
"main": "generate.js",
|
||||
"main": "dist/generate.js",
|
||||
"bin": {
|
||||
"generate-clean-arch": "./generate.js"
|
||||
"generate-clean-arch": "./dist/generate.js"
|
||||
},
|
||||
"scripts": {
|
||||
"generate": "node generate.js",
|
||||
"build": "tsc",
|
||||
"prepublishOnly": "npm run build",
|
||||
"generate": "node dist/generate.js",
|
||||
"generate:dev": "ts-node generate.ts",
|
||||
"setup": "npm install -g @openapitools/openapi-generator-cli"
|
||||
},
|
||||
"keywords": [
|
||||
@@ -28,5 +31,13 @@
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=14.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/fs-extra": "^11.0.4",
|
||||
"@types/js-yaml": "^4.0.9",
|
||||
"@types/mustache": "^4.2.6",
|
||||
"@types/node": "^25.5.0",
|
||||
"ts-node": "^10.9.2",
|
||||
"typescript": "^5.9.3"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user