create-huenei-template 0.2.7 → 0.2.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (467) hide show
  1. package/dist/config/templates.js +7 -0
  2. package/dist/templates/README.md +7 -1
  3. package/dist/templates/backend/README.md +19 -9
  4. package/dist/templates/backend/nestjs-api-mysql/.cursor/agents/nestjs-code-reviewer.md +54 -0
  5. package/dist/templates/backend/nestjs-api-mysql/.cursor/agents/prisma-guardian.md +67 -0
  6. package/dist/templates/backend/nestjs-api-mysql/.cursor/agents/test-runner.md +57 -0
  7. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks/autoTestOnStop.ts +127 -0
  8. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks/blockDangerous.ts +98 -0
  9. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks/ensureTestsExist.ts +405 -0
  10. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks/formatOnEdit.ts +70 -0
  11. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks/protectSecrets.ts +101 -0
  12. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks/sessionInit.ts +104 -0
  13. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks/validatePrisma.ts +121 -0
  14. package/dist/templates/backend/nestjs-api-mysql/.cursor/hooks.json +46 -0
  15. package/dist/templates/backend/nestjs-api-mysql/README.md +26 -0
  16. package/dist/templates/backend/nestjs-api-mysql/eslint.config.mjs +1 -1
  17. package/dist/templates/backend/nestjs-api-mysql/package.json +7 -7
  18. package/dist/templates/backend/nestjs-api-postgres/.cursor/agents/nestjs-code-reviewer.md +54 -0
  19. package/dist/templates/backend/nestjs-api-postgres/.cursor/agents/prisma-guardian.md +62 -0
  20. package/dist/templates/backend/nestjs-api-postgres/.cursor/agents/security-auditor.md +71 -0
  21. package/dist/templates/backend/nestjs-api-postgres/.cursor/agents/test-runner.md +58 -0
  22. package/dist/templates/backend/nestjs-api-postgres/.cursor/hooks/auto-retry.ts +62 -0
  23. package/dist/templates/backend/nestjs-api-postgres/.cursor/hooks/block-dangerous.ts +202 -0
  24. package/dist/templates/backend/nestjs-api-postgres/.cursor/hooks/format-and-validate.ts +124 -0
  25. package/dist/templates/backend/nestjs-api-postgres/.cursor/hooks/protect-secrets.ts +105 -0
  26. package/dist/templates/backend/nestjs-api-postgres/.cursor/hooks/session-context.ts +130 -0
  27. package/dist/templates/backend/nestjs-api-postgres/.cursor/hooks.json +36 -0
  28. package/dist/templates/backend/nestjs-api-postgres/eslint.config.mjs +1 -1
  29. package/dist/templates/backend/nestjs-api-postgres/package.json +6 -6
  30. package/dist/templates/backend/nestjs-api-sqlite/.cursor/agents/code-reviewer.md +153 -0
  31. package/dist/templates/backend/nestjs-api-sqlite/.cursor/agents/nestjs-architect.md +138 -0
  32. package/dist/templates/backend/nestjs-api-sqlite/.cursor/agents/prisma-analyst.md +164 -0
  33. package/dist/templates/backend/nestjs-api-sqlite/.cursor/agents/security-auditor.md +150 -0
  34. package/dist/templates/backend/nestjs-api-sqlite/.cursor/agents/test-engineer.md +290 -0
  35. package/dist/templates/backend/nestjs-api-sqlite/.cursor/hooks/auto-format.ts +80 -0
  36. package/dist/templates/backend/nestjs-api-sqlite/.cursor/hooks/block-dangerous-commands.ts +144 -0
  37. package/dist/templates/backend/nestjs-api-sqlite/.cursor/hooks/prisma-schema-watcher.ts +64 -0
  38. package/dist/templates/backend/nestjs-api-sqlite/.cursor/hooks/protect-sensitive-files.ts +122 -0
  39. package/dist/templates/backend/nestjs-api-sqlite/.cursor/hooks/session-context.ts +105 -0
  40. package/dist/templates/backend/nestjs-api-sqlite/.cursor/hooks.json +18 -0
  41. package/dist/templates/backend/nestjs-api-sqlite/.cursor/skills/conventional-commits/SKILL.md +318 -0
  42. package/dist/templates/backend/nestjs-api-sqlite/.cursor/skills/docker/SKILL.md +82 -0
  43. package/dist/templates/backend/nestjs-api-sqlite/.cursor/skills/jest/SKILL.md +72 -0
  44. package/dist/templates/backend/nestjs-api-sqlite/.cursor/skills/logging-best-practices/SKILL.md +127 -0
  45. package/dist/templates/backend/nestjs-api-sqlite/.cursor/skills/prisma-database-setup/SKILL.md +186 -0
  46. package/dist/templates/backend/nestjs-api-sqlite/.cursor/skills/quality-gates-enforcer/SKILL.md +301 -0
  47. package/dist/templates/backend/nestjs-api-sqlite/README.md +34 -1
  48. package/dist/templates/backend/nestjs-api-sqlite/eslint.config.mjs +1 -1
  49. package/dist/templates/backend/nestjs-api-sqlite/package.json +6 -6
  50. package/dist/templates/backend/nestjs-api-sqlite/prisma/schema.prisma +1 -0
  51. package/dist/templates/backend/nestjs-api-sqlite/prisma/seed.ts +2 -2
  52. package/dist/templates/backend/nestjs-api-sqlite/src/posts/dto/post-response.dto.ts +5 -1
  53. package/dist/templates/backend/nestjs-api-sqlite/src/users/dto/profile-response.dto.ts +1 -1
  54. package/dist/templates/backend/nestjs-api-sqlite/src/users/dto/update-profile.dto.ts +1 -1
  55. package/dist/templates/backend/nestjs-api-sqlite/src/users/dto/user-response.dto.ts +4 -0
  56. package/dist/templates/backend/nestjs-api-sqlite/src/users/profile.service.ts +24 -8
  57. package/dist/templates/backend/nestjs-api-sqlite/src/users/users.service.ts +1 -0
  58. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/agents/nestjs-code-reviewer.md +54 -0
  59. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/agents/prisma-guardian.md +67 -0
  60. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/agents/test-runner.md +57 -0
  61. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/commands/new-endpoint.md +209 -0
  62. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/commands/new-model.md +201 -0
  63. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks/autoTestOnStop.ts +127 -0
  64. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks/blockDangerous.ts +98 -0
  65. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks/ensureTestsExist.ts +405 -0
  66. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks/formatOnEdit.ts +70 -0
  67. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks/protectSecrets.ts +101 -0
  68. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks/sessionInit.ts +104 -0
  69. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks/validatePrisma.ts +121 -0
  70. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/hooks.json +46 -0
  71. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/rules/api-rest.mdc +126 -0
  72. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/rules/authentication-security.mdc +86 -0
  73. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/rules/dto-validation.mdc +93 -0
  74. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/rules/general-rules.mdc +126 -0
  75. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/rules/nestjs-architecture.mdc +83 -0
  76. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/rules/prisma-standards.mdc +111 -0
  77. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/rules/swagger-documentation.mdc +90 -0
  78. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/api-security-best-practices/SKILL.md +907 -0
  79. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/docker-expert/SKILL.md +409 -0
  80. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/nestjs-expert/SKILL.md +552 -0
  81. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/nestjs-the-best-practices/AGENTS.md +5958 -0
  82. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/nestjs-the-best-practices/SKILL.md +130 -0
  83. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/nodejs-best-practices/SKILL.md +333 -0
  84. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/prisma-expert/SKILL.md +355 -0
  85. package/dist/templates/backend/nestjs-api-sqlserver/.cursor/skills/sqlserver-table-design/SKILL.md +125 -0
  86. package/dist/templates/backend/nestjs-api-sqlserver/.dockerignore +50 -0
  87. package/dist/templates/backend/nestjs-api-sqlserver/.env.example +17 -0
  88. package/dist/templates/backend/nestjs-api-sqlserver/.env.test +17 -0
  89. package/dist/templates/backend/nestjs-api-sqlserver/.prettierrc +4 -0
  90. package/dist/templates/backend/nestjs-api-sqlserver/README.md +587 -0
  91. package/dist/templates/backend/nestjs-api-sqlserver/docker-compose.yml +24 -0
  92. package/dist/templates/backend/nestjs-api-sqlserver/eslint.config.mjs +41 -0
  93. package/dist/templates/backend/nestjs-api-sqlserver/nest-cli.json +8 -0
  94. package/dist/templates/backend/nestjs-api-sqlserver/package.json +107 -0
  95. package/dist/templates/backend/nestjs-api-sqlserver/prisma/schema.prisma +70 -0
  96. package/dist/templates/backend/nestjs-api-sqlserver/prisma/seed.ts +215 -0
  97. package/dist/templates/backend/nestjs-api-sqlserver/prisma.config.ts +12 -0
  98. package/dist/templates/backend/nestjs-api-sqlserver/scripts/check-docker.js +64 -0
  99. package/dist/templates/backend/nestjs-api-sqlserver/src/app.module.ts +39 -0
  100. package/dist/templates/backend/nestjs-api-sqlserver/src/app.service.ts +8 -0
  101. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/auth.controller.ts +36 -0
  102. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/auth.module.ts +22 -0
  103. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/auth.service.ts +64 -0
  104. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/decorators/roles.decorator.ts +5 -0
  105. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/dto/login-response.dto.ts +23 -0
  106. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/dto/login.dto.ts +27 -0
  107. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/enums/role.enum.ts +5 -0
  108. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/guards/jwt-auth.guard.ts +20 -0
  109. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/guards/roles.guard.ts +23 -0
  110. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/strategies/jwt.strategy.ts +32 -0
  111. package/dist/templates/backend/nestjs-api-sqlserver/src/auth/types.ts +18 -0
  112. package/dist/templates/backend/nestjs-api-sqlserver/src/common/dto/paginated-response.dto.ts +16 -0
  113. package/dist/templates/backend/nestjs-api-sqlserver/src/common/dto/pagination.dto.ts +31 -0
  114. package/dist/templates/backend/nestjs-api-sqlserver/src/common/filters/http-exception.filter.ts +53 -0
  115. package/dist/templates/backend/nestjs-api-sqlserver/src/config/env.validation.ts +41 -0
  116. package/dist/templates/backend/nestjs-api-sqlserver/src/health/health.controller.ts +35 -0
  117. package/dist/templates/backend/nestjs-api-sqlserver/src/health/health.module.ts +7 -0
  118. package/dist/templates/backend/nestjs-api-sqlserver/src/main.ts +87 -0
  119. package/dist/templates/backend/nestjs-api-sqlserver/src/posts/dto/create-post.dto.ts +32 -0
  120. package/dist/templates/backend/nestjs-api-sqlserver/src/posts/dto/post-response.dto.ts +41 -0
  121. package/dist/templates/backend/nestjs-api-sqlserver/src/posts/dto/update-post.dto.ts +31 -0
  122. package/dist/templates/backend/nestjs-api-sqlserver/src/posts/posts.controller.ts +161 -0
  123. package/dist/templates/backend/nestjs-api-sqlserver/src/posts/posts.module.ts +12 -0
  124. package/dist/templates/backend/nestjs-api-sqlserver/src/posts/posts.service.ts +171 -0
  125. package/dist/templates/backend/nestjs-api-sqlserver/src/prisma/prisma.module.ts +9 -0
  126. package/dist/templates/backend/nestjs-api-sqlserver/src/prisma/prisma.service.ts +62 -0
  127. package/dist/templates/backend/nestjs-api-sqlserver/src/users/constants/settings.constants.ts +9 -0
  128. package/dist/templates/backend/nestjs-api-sqlserver/src/users/dto/profile-response.dto.ts +39 -0
  129. package/dist/templates/backend/nestjs-api-sqlserver/src/users/dto/settings-response.dto.ts +18 -0
  130. package/dist/templates/backend/nestjs-api-sqlserver/src/users/dto/update-profile.dto.ts +48 -0
  131. package/dist/templates/backend/nestjs-api-sqlserver/src/users/dto/update-settings.dto.ts +40 -0
  132. package/dist/templates/backend/nestjs-api-sqlserver/src/users/dto/user-response.dto.ts +18 -0
  133. package/dist/templates/backend/nestjs-api-sqlserver/src/users/profile.service.ts +67 -0
  134. package/dist/templates/backend/nestjs-api-sqlserver/src/users/settings.service.ts +77 -0
  135. package/dist/templates/backend/nestjs-api-sqlserver/src/users/users.controller.ts +102 -0
  136. package/dist/templates/backend/nestjs-api-sqlserver/src/users/users.module.ts +14 -0
  137. package/dist/templates/backend/nestjs-api-sqlserver/src/users/users.service.ts +27 -0
  138. package/dist/templates/backend/nestjs-api-sqlserver/test/README.md +412 -0
  139. package/dist/templates/backend/nestjs-api-sqlserver/test/e2e/auth.e2e-spec.ts +147 -0
  140. package/dist/templates/backend/nestjs-api-sqlserver/test/e2e/health.e2e-spec.ts +62 -0
  141. package/dist/templates/backend/nestjs-api-sqlserver/test/e2e/posts.e2e-spec.ts +407 -0
  142. package/dist/templates/backend/nestjs-api-sqlserver/test/e2e/users.e2e-spec.ts +287 -0
  143. package/dist/templates/backend/nestjs-api-sqlserver/test/fixtures/test-data.ts +109 -0
  144. package/dist/templates/backend/nestjs-api-sqlserver/test/helpers/auth.helper.ts +54 -0
  145. package/dist/templates/backend/nestjs-api-sqlserver/test/helpers/db.helper.ts +68 -0
  146. package/dist/templates/backend/nestjs-api-sqlserver/test/jest-e2e.json +12 -0
  147. package/dist/templates/backend/nestjs-api-sqlserver/test/setup-e2e.ts +8 -0
  148. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/app.service.spec.ts +24 -0
  149. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/auth.controller.spec.ts +91 -0
  150. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/auth.service.spec.ts +161 -0
  151. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/health.controller.spec.ts +78 -0
  152. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/http-exception.filter.spec.ts +150 -0
  153. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/jwt-auth.guard.spec.ts +50 -0
  154. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/jwt.strategy.spec.ts +41 -0
  155. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/posts.controller.spec.ts +249 -0
  156. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/posts.service.spec.ts +328 -0
  157. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/profile.service.spec.ts +146 -0
  158. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/settings.service.spec.ts +242 -0
  159. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/users.controller.spec.ts +178 -0
  160. package/dist/templates/backend/nestjs-api-sqlserver/test/unit/users.service.spec.ts +96 -0
  161. package/dist/templates/backend/nestjs-api-sqlserver/tsconfig.build.json +4 -0
  162. package/dist/templates/backend/nestjs-api-sqlserver/tsconfig.json +28 -0
  163. package/dist/templates/frontend/angular-base/.cursor/agents/accessibility-reviewer.md +67 -0
  164. package/dist/templates/frontend/angular-base/.cursor/agents/angular-code-reviewer.md +60 -0
  165. package/dist/templates/frontend/angular-base/.cursor/agents/qa-test-expert.md +70 -0
  166. package/dist/templates/frontend/angular-base/.cursor/agents/security-auditor.md +58 -0
  167. package/dist/templates/frontend/angular-base/.cursor/hooks/auto-format.ts +70 -0
  168. package/dist/templates/frontend/angular-base/.cursor/hooks/auto-test-on-stop.ts +113 -0
  169. package/dist/templates/frontend/angular-base/.cursor/hooks/block-dangerous-commands.ts +160 -0
  170. package/dist/templates/frontend/angular-base/.cursor/hooks/ensure-tests-exist.ts +363 -0
  171. package/dist/templates/frontend/angular-base/.cursor/hooks/protect-sensitive-files.ts +118 -0
  172. package/dist/templates/frontend/angular-base/.cursor/hooks/session-context.ts +110 -0
  173. package/dist/templates/frontend/angular-base/.cursor/hooks.json +41 -0
  174. package/dist/templates/frontend/angular-nx/.cursor/agents/angular-code-reviewer.md +64 -0
  175. package/dist/templates/frontend/angular-nx/.cursor/agents/nx-architecture-guardian.md +69 -0
  176. package/dist/templates/frontend/angular-nx/.cursor/agents/qa-test-expert.md +75 -0
  177. package/dist/templates/frontend/angular-nx/.cursor/agents/security-auditor.md +61 -0
  178. package/dist/templates/frontend/angular-nx/.cursor/hooks/auto-format.ts +70 -0
  179. package/dist/templates/frontend/angular-nx/.cursor/hooks/auto-test-on-stop.ts +115 -0
  180. package/dist/templates/frontend/angular-nx/.cursor/hooks/block-dangerous-commands.ts +188 -0
  181. package/dist/templates/frontend/angular-nx/.cursor/hooks/ensure-tests-exist.ts +399 -0
  182. package/dist/templates/frontend/angular-nx/.cursor/hooks/protect-sensitive-files.ts +128 -0
  183. package/dist/templates/frontend/angular-nx/.cursor/hooks/session-context.ts +121 -0
  184. package/dist/templates/frontend/angular-nx/.cursor/hooks.json +41 -0
  185. package/dist/templates/frontend/react-vite/.cursor/agents/frontend-senior.agent.md +49 -49
  186. package/dist/templates/frontend/react-vite/.cursor/agents/qa-test-expert.agent.md +126 -49
  187. package/dist/templates/frontend/react-vite/.cursor/agents/security-expert.agent.md +39 -39
  188. package/dist/templates/frontend/react-vite/.cursor/agents/ux-ui-expert.agent.md +45 -45
  189. package/dist/templates/frontend/react-vite/.cursor/hooks/autoTestOnStop.ts +117 -0
  190. package/dist/templates/frontend/react-vite/.cursor/hooks/blockDangerous.ts +75 -0
  191. package/dist/templates/frontend/react-vite/.cursor/hooks/ensureTestsExist.ts +306 -220
  192. package/dist/templates/frontend/react-vite/.cursor/hooks/formatOnEdit.ts +49 -0
  193. package/dist/templates/frontend/react-vite/.cursor/hooks/protectSecrets.ts +88 -0
  194. package/dist/templates/frontend/react-vite/.cursor/hooks/sessionInit.ts +77 -0
  195. package/dist/templates/frontend/react-vite/.cursor/hooks.json +41 -10
  196. package/dist/templates/frontend/react-vite/.cursor/settings.json +13 -13
  197. package/dist/templates/frontend/react-vite/.vscode/settings.json +31 -31
  198. package/dist/templates/frontend/react-vite/README.md +34 -34
  199. package/dist/templates/frontend/react-vite/package.json +82 -82
  200. package/dist/templates/frontend/react-vite/pnpm-lock.yaml +6575 -6575
  201. package/dist/templates/frontend/react-vite/src/__tests__/components/layout/navbar.test.tsx +63 -0
  202. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/avatar.test.tsx +74 -0
  203. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/badge.test.tsx +55 -0
  204. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/breadcrumb.test.tsx +140 -0
  205. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/button.test.tsx +121 -0
  206. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/card.test.tsx +144 -0
  207. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/dialog.test.tsx +121 -0
  208. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/form.test.tsx +165 -0
  209. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/input.test.tsx +52 -0
  210. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/label.test.tsx +40 -0
  211. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/password-input.test.tsx +59 -0
  212. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/separator.test.tsx +40 -0
  213. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/table.test.tsx +254 -0
  214. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/tabs.test.tsx +82 -0
  215. package/dist/templates/frontend/react-vite/src/__tests__/components/ui/textarea.test.tsx +47 -0
  216. package/dist/templates/frontend/react-vite/src/__tests__/helpers/render.tsx +114 -0
  217. package/dist/templates/frontend/react-vite/src/__tests__/hooks/useLocalStorage.test.ts +95 -0
  218. package/dist/templates/frontend/react-vite/src/__tests__/lib/queryClient.test.ts +24 -0
  219. package/dist/templates/frontend/react-vite/src/__tests__/lib/utils.test.ts +43 -0
  220. package/dist/templates/frontend/react-vite/src/__tests__/routes/index.test.tsx +111 -0
  221. package/dist/templates/frontend/react-vite/src/__tests__/routes/otra-ruta.test.tsx +126 -0
  222. package/dist/templates/frontend/react-vite/src/__tests__/routes/root.test.tsx +78 -0
  223. package/dist/templates/frontend/react-vite/src/__tests__/routes/ui-components.test.tsx +286 -0
  224. package/dist/templates/frontend/react-vite/src/components/layout/navbar.tsx +38 -38
  225. package/dist/templates/frontend/react-vite/src/components/ui/avatar.tsx +42 -42
  226. package/dist/templates/frontend/react-vite/src/components/ui/dialog.tsx +122 -122
  227. package/dist/templates/frontend/react-vite/src/components/ui/table.tsx +229 -244
  228. package/dist/templates/frontend/react-vite/src/hooks/useLocalStorage.ts +32 -32
  229. package/dist/templates/frontend/react-vite/src/routes/__root.tsx +48 -48
  230. package/dist/templates/frontend/react-vite/src/routes/ui-components.tsx +359 -85
  231. package/dist/templates/frontend/react-vite/src/test/setup.ts +24 -24
  232. package/dist/templates/frontend/react-vite/vite.config.ts +2 -2
  233. package/dist/templates/frontend/react-vite/vitest.config.ts +13 -2
  234. package/package.json +1 -1
  235. package/templates/README.md +7 -1
  236. package/templates/backend/README.md +19 -9
  237. package/templates/backend/nestjs-api-mysql/.cursor/agents/nestjs-code-reviewer.md +54 -0
  238. package/templates/backend/nestjs-api-mysql/.cursor/agents/prisma-guardian.md +67 -0
  239. package/templates/backend/nestjs-api-mysql/.cursor/agents/test-runner.md +57 -0
  240. package/templates/backend/nestjs-api-mysql/.cursor/hooks/autoTestOnStop.ts +127 -0
  241. package/templates/backend/nestjs-api-mysql/.cursor/hooks/blockDangerous.ts +98 -0
  242. package/templates/backend/nestjs-api-mysql/.cursor/hooks/ensureTestsExist.ts +405 -0
  243. package/templates/backend/nestjs-api-mysql/.cursor/hooks/formatOnEdit.ts +70 -0
  244. package/templates/backend/nestjs-api-mysql/.cursor/hooks/protectSecrets.ts +101 -0
  245. package/templates/backend/nestjs-api-mysql/.cursor/hooks/sessionInit.ts +104 -0
  246. package/templates/backend/nestjs-api-mysql/.cursor/hooks/validatePrisma.ts +121 -0
  247. package/templates/backend/nestjs-api-mysql/.cursor/hooks.json +46 -0
  248. package/templates/backend/nestjs-api-mysql/README.md +26 -0
  249. package/templates/backend/nestjs-api-mysql/dist/tsconfig.build.tsbuildinfo +1 -1
  250. package/templates/backend/nestjs-api-mysql/eslint.config.mjs +1 -1
  251. package/templates/backend/nestjs-api-mysql/package.json +7 -7
  252. package/templates/backend/nestjs-api-postgres/.cursor/agents/nestjs-code-reviewer.md +54 -0
  253. package/templates/backend/nestjs-api-postgres/.cursor/agents/prisma-guardian.md +62 -0
  254. package/templates/backend/nestjs-api-postgres/.cursor/agents/security-auditor.md +71 -0
  255. package/templates/backend/nestjs-api-postgres/.cursor/agents/test-runner.md +58 -0
  256. package/templates/backend/nestjs-api-postgres/.cursor/hooks/auto-retry.ts +62 -0
  257. package/templates/backend/nestjs-api-postgres/.cursor/hooks/block-dangerous.ts +202 -0
  258. package/templates/backend/nestjs-api-postgres/.cursor/hooks/format-and-validate.ts +124 -0
  259. package/templates/backend/nestjs-api-postgres/.cursor/hooks/protect-secrets.ts +105 -0
  260. package/templates/backend/nestjs-api-postgres/.cursor/hooks/session-context.ts +130 -0
  261. package/templates/backend/nestjs-api-postgres/.cursor/hooks.json +36 -0
  262. package/templates/backend/nestjs-api-postgres/eslint.config.mjs +1 -1
  263. package/templates/backend/nestjs-api-postgres/package.json +6 -6
  264. package/templates/backend/nestjs-api-sqlite/.cursor/agents/code-reviewer.md +153 -0
  265. package/templates/backend/nestjs-api-sqlite/.cursor/agents/nestjs-architect.md +138 -0
  266. package/templates/backend/nestjs-api-sqlite/.cursor/agents/prisma-analyst.md +164 -0
  267. package/templates/backend/nestjs-api-sqlite/.cursor/agents/security-auditor.md +150 -0
  268. package/templates/backend/nestjs-api-sqlite/.cursor/agents/test-engineer.md +290 -0
  269. package/templates/backend/nestjs-api-sqlite/.cursor/hooks/auto-format.ts +80 -0
  270. package/templates/backend/nestjs-api-sqlite/.cursor/hooks/block-dangerous-commands.ts +144 -0
  271. package/templates/backend/nestjs-api-sqlite/.cursor/hooks/prisma-schema-watcher.ts +64 -0
  272. package/templates/backend/nestjs-api-sqlite/.cursor/hooks/protect-sensitive-files.ts +122 -0
  273. package/templates/backend/nestjs-api-sqlite/.cursor/hooks/session-context.ts +105 -0
  274. package/templates/backend/nestjs-api-sqlite/.cursor/hooks.json +18 -0
  275. package/templates/backend/nestjs-api-sqlite/.cursor/skills/conventional-commits/SKILL.md +318 -0
  276. package/templates/backend/nestjs-api-sqlite/.cursor/skills/docker/SKILL.md +82 -0
  277. package/templates/backend/nestjs-api-sqlite/.cursor/skills/jest/SKILL.md +72 -0
  278. package/templates/backend/nestjs-api-sqlite/.cursor/skills/logging-best-practices/SKILL.md +127 -0
  279. package/templates/backend/nestjs-api-sqlite/.cursor/skills/prisma-database-setup/SKILL.md +186 -0
  280. package/templates/backend/nestjs-api-sqlite/.cursor/skills/quality-gates-enforcer/SKILL.md +301 -0
  281. package/templates/backend/nestjs-api-sqlite/README.md +34 -1
  282. package/templates/backend/nestjs-api-sqlite/eslint.config.mjs +1 -1
  283. package/templates/backend/nestjs-api-sqlite/package.json +6 -6
  284. package/templates/backend/nestjs-api-sqlite/prisma/schema.prisma +1 -0
  285. package/templates/backend/nestjs-api-sqlite/prisma/seed.ts +2 -2
  286. package/templates/backend/nestjs-api-sqlite/src/posts/dto/post-response.dto.ts +5 -1
  287. package/templates/backend/nestjs-api-sqlite/src/users/dto/profile-response.dto.ts +1 -1
  288. package/templates/backend/nestjs-api-sqlite/src/users/dto/update-profile.dto.ts +1 -1
  289. package/templates/backend/nestjs-api-sqlite/src/users/dto/user-response.dto.ts +4 -0
  290. package/templates/backend/nestjs-api-sqlite/src/users/profile.service.ts +24 -8
  291. package/templates/backend/nestjs-api-sqlite/src/users/users.service.ts +1 -0
  292. package/templates/backend/nestjs-api-sqlserver/.cursor/agents/nestjs-code-reviewer.md +54 -0
  293. package/templates/backend/nestjs-api-sqlserver/.cursor/agents/prisma-guardian.md +67 -0
  294. package/templates/backend/nestjs-api-sqlserver/.cursor/agents/test-runner.md +57 -0
  295. package/templates/backend/nestjs-api-sqlserver/.cursor/commands/new-endpoint.md +209 -0
  296. package/templates/backend/nestjs-api-sqlserver/.cursor/commands/new-model.md +201 -0
  297. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks/autoTestOnStop.ts +127 -0
  298. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks/blockDangerous.ts +98 -0
  299. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks/ensureTestsExist.ts +405 -0
  300. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks/formatOnEdit.ts +70 -0
  301. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks/protectSecrets.ts +101 -0
  302. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks/sessionInit.ts +104 -0
  303. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks/validatePrisma.ts +121 -0
  304. package/templates/backend/nestjs-api-sqlserver/.cursor/hooks.json +46 -0
  305. package/templates/backend/nestjs-api-sqlserver/.cursor/rules/api-rest.mdc +126 -0
  306. package/templates/backend/nestjs-api-sqlserver/.cursor/rules/authentication-security.mdc +86 -0
  307. package/templates/backend/nestjs-api-sqlserver/.cursor/rules/dto-validation.mdc +93 -0
  308. package/templates/backend/nestjs-api-sqlserver/.cursor/rules/general-rules.mdc +126 -0
  309. package/templates/backend/nestjs-api-sqlserver/.cursor/rules/nestjs-architecture.mdc +83 -0
  310. package/templates/backend/nestjs-api-sqlserver/.cursor/rules/prisma-standards.mdc +111 -0
  311. package/templates/backend/nestjs-api-sqlserver/.cursor/rules/swagger-documentation.mdc +90 -0
  312. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/api-security-best-practices/SKILL.md +907 -0
  313. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/docker-expert/SKILL.md +409 -0
  314. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/nestjs-expert/SKILL.md +552 -0
  315. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/nestjs-the-best-practices/AGENTS.md +5958 -0
  316. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/nestjs-the-best-practices/SKILL.md +130 -0
  317. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/nodejs-best-practices/SKILL.md +333 -0
  318. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/prisma-expert/SKILL.md +355 -0
  319. package/templates/backend/nestjs-api-sqlserver/.cursor/skills/sqlserver-table-design/SKILL.md +125 -0
  320. package/templates/backend/nestjs-api-sqlserver/.dockerignore +50 -0
  321. package/templates/backend/nestjs-api-sqlserver/.env.example +17 -0
  322. package/templates/backend/nestjs-api-sqlserver/.env.test +17 -0
  323. package/templates/backend/nestjs-api-sqlserver/.prettierrc +4 -0
  324. package/templates/backend/nestjs-api-sqlserver/README.md +587 -0
  325. package/templates/backend/nestjs-api-sqlserver/docker-compose.yml +24 -0
  326. package/templates/backend/nestjs-api-sqlserver/eslint.config.mjs +41 -0
  327. package/templates/backend/nestjs-api-sqlserver/nest-cli.json +8 -0
  328. package/templates/backend/nestjs-api-sqlserver/package.json +107 -0
  329. package/templates/backend/nestjs-api-sqlserver/prisma/schema.prisma +70 -0
  330. package/templates/backend/nestjs-api-sqlserver/prisma/seed.ts +215 -0
  331. package/templates/backend/nestjs-api-sqlserver/prisma.config.ts +12 -0
  332. package/templates/backend/nestjs-api-sqlserver/scripts/check-docker.js +64 -0
  333. package/templates/backend/nestjs-api-sqlserver/src/app.module.ts +39 -0
  334. package/templates/backend/nestjs-api-sqlserver/src/app.service.ts +8 -0
  335. package/templates/backend/nestjs-api-sqlserver/src/auth/auth.controller.ts +36 -0
  336. package/templates/backend/nestjs-api-sqlserver/src/auth/auth.module.ts +22 -0
  337. package/templates/backend/nestjs-api-sqlserver/src/auth/auth.service.ts +64 -0
  338. package/templates/backend/nestjs-api-sqlserver/src/auth/decorators/roles.decorator.ts +5 -0
  339. package/templates/backend/nestjs-api-sqlserver/src/auth/dto/login-response.dto.ts +23 -0
  340. package/templates/backend/nestjs-api-sqlserver/src/auth/dto/login.dto.ts +27 -0
  341. package/templates/backend/nestjs-api-sqlserver/src/auth/enums/role.enum.ts +5 -0
  342. package/templates/backend/nestjs-api-sqlserver/src/auth/guards/jwt-auth.guard.ts +20 -0
  343. package/templates/backend/nestjs-api-sqlserver/src/auth/guards/roles.guard.ts +23 -0
  344. package/templates/backend/nestjs-api-sqlserver/src/auth/strategies/jwt.strategy.ts +32 -0
  345. package/templates/backend/nestjs-api-sqlserver/src/auth/types.ts +18 -0
  346. package/templates/backend/nestjs-api-sqlserver/src/common/dto/paginated-response.dto.ts +16 -0
  347. package/templates/backend/nestjs-api-sqlserver/src/common/dto/pagination.dto.ts +31 -0
  348. package/templates/backend/nestjs-api-sqlserver/src/common/filters/http-exception.filter.ts +53 -0
  349. package/templates/backend/nestjs-api-sqlserver/src/config/env.validation.ts +41 -0
  350. package/templates/backend/nestjs-api-sqlserver/src/health/health.controller.ts +35 -0
  351. package/templates/backend/nestjs-api-sqlserver/src/health/health.module.ts +7 -0
  352. package/templates/backend/nestjs-api-sqlserver/src/main.ts +87 -0
  353. package/templates/backend/nestjs-api-sqlserver/src/posts/dto/create-post.dto.ts +32 -0
  354. package/templates/backend/nestjs-api-sqlserver/src/posts/dto/post-response.dto.ts +41 -0
  355. package/templates/backend/nestjs-api-sqlserver/src/posts/dto/update-post.dto.ts +31 -0
  356. package/templates/backend/nestjs-api-sqlserver/src/posts/posts.controller.ts +161 -0
  357. package/templates/backend/nestjs-api-sqlserver/src/posts/posts.module.ts +12 -0
  358. package/templates/backend/nestjs-api-sqlserver/src/posts/posts.service.ts +171 -0
  359. package/templates/backend/nestjs-api-sqlserver/src/prisma/prisma.module.ts +9 -0
  360. package/templates/backend/nestjs-api-sqlserver/src/prisma/prisma.service.ts +62 -0
  361. package/templates/backend/nestjs-api-sqlserver/src/users/constants/settings.constants.ts +9 -0
  362. package/templates/backend/nestjs-api-sqlserver/src/users/dto/profile-response.dto.ts +39 -0
  363. package/templates/backend/nestjs-api-sqlserver/src/users/dto/settings-response.dto.ts +18 -0
  364. package/templates/backend/nestjs-api-sqlserver/src/users/dto/update-profile.dto.ts +48 -0
  365. package/templates/backend/nestjs-api-sqlserver/src/users/dto/update-settings.dto.ts +40 -0
  366. package/templates/backend/nestjs-api-sqlserver/src/users/dto/user-response.dto.ts +18 -0
  367. package/templates/backend/nestjs-api-sqlserver/src/users/profile.service.ts +67 -0
  368. package/templates/backend/nestjs-api-sqlserver/src/users/settings.service.ts +77 -0
  369. package/templates/backend/nestjs-api-sqlserver/src/users/users.controller.ts +102 -0
  370. package/templates/backend/nestjs-api-sqlserver/src/users/users.module.ts +14 -0
  371. package/templates/backend/nestjs-api-sqlserver/src/users/users.service.ts +27 -0
  372. package/templates/backend/nestjs-api-sqlserver/test/README.md +412 -0
  373. package/templates/backend/nestjs-api-sqlserver/test/e2e/auth.e2e-spec.ts +147 -0
  374. package/templates/backend/nestjs-api-sqlserver/test/e2e/health.e2e-spec.ts +62 -0
  375. package/templates/backend/nestjs-api-sqlserver/test/e2e/posts.e2e-spec.ts +407 -0
  376. package/templates/backend/nestjs-api-sqlserver/test/e2e/users.e2e-spec.ts +287 -0
  377. package/templates/backend/nestjs-api-sqlserver/test/fixtures/test-data.ts +109 -0
  378. package/templates/backend/nestjs-api-sqlserver/test/helpers/auth.helper.ts +54 -0
  379. package/templates/backend/nestjs-api-sqlserver/test/helpers/db.helper.ts +68 -0
  380. package/templates/backend/nestjs-api-sqlserver/test/jest-e2e.json +12 -0
  381. package/templates/backend/nestjs-api-sqlserver/test/setup-e2e.ts +8 -0
  382. package/templates/backend/nestjs-api-sqlserver/test/unit/app.service.spec.ts +24 -0
  383. package/templates/backend/nestjs-api-sqlserver/test/unit/auth.controller.spec.ts +91 -0
  384. package/templates/backend/nestjs-api-sqlserver/test/unit/auth.service.spec.ts +161 -0
  385. package/templates/backend/nestjs-api-sqlserver/test/unit/health.controller.spec.ts +78 -0
  386. package/templates/backend/nestjs-api-sqlserver/test/unit/http-exception.filter.spec.ts +150 -0
  387. package/templates/backend/nestjs-api-sqlserver/test/unit/jwt-auth.guard.spec.ts +50 -0
  388. package/templates/backend/nestjs-api-sqlserver/test/unit/jwt.strategy.spec.ts +41 -0
  389. package/templates/backend/nestjs-api-sqlserver/test/unit/posts.controller.spec.ts +249 -0
  390. package/templates/backend/nestjs-api-sqlserver/test/unit/posts.service.spec.ts +328 -0
  391. package/templates/backend/nestjs-api-sqlserver/test/unit/profile.service.spec.ts +146 -0
  392. package/templates/backend/nestjs-api-sqlserver/test/unit/settings.service.spec.ts +242 -0
  393. package/templates/backend/nestjs-api-sqlserver/test/unit/users.controller.spec.ts +178 -0
  394. package/templates/backend/nestjs-api-sqlserver/test/unit/users.service.spec.ts +96 -0
  395. package/templates/backend/nestjs-api-sqlserver/tsconfig.build.json +4 -0
  396. package/templates/backend/nestjs-api-sqlserver/tsconfig.json +28 -0
  397. package/templates/frontend/angular-base/.cursor/agents/accessibility-reviewer.md +67 -0
  398. package/templates/frontend/angular-base/.cursor/agents/angular-code-reviewer.md +60 -0
  399. package/templates/frontend/angular-base/.cursor/agents/qa-test-expert.md +70 -0
  400. package/templates/frontend/angular-base/.cursor/agents/security-auditor.md +58 -0
  401. package/templates/frontend/angular-base/.cursor/hooks/auto-format.ts +70 -0
  402. package/templates/frontend/angular-base/.cursor/hooks/auto-test-on-stop.ts +113 -0
  403. package/templates/frontend/angular-base/.cursor/hooks/block-dangerous-commands.ts +160 -0
  404. package/templates/frontend/angular-base/.cursor/hooks/ensure-tests-exist.ts +363 -0
  405. package/templates/frontend/angular-base/.cursor/hooks/protect-sensitive-files.ts +118 -0
  406. package/templates/frontend/angular-base/.cursor/hooks/session-context.ts +110 -0
  407. package/templates/frontend/angular-base/.cursor/hooks.json +41 -0
  408. package/templates/frontend/angular-nx/.cursor/agents/angular-code-reviewer.md +64 -0
  409. package/templates/frontend/angular-nx/.cursor/agents/nx-architecture-guardian.md +69 -0
  410. package/templates/frontend/angular-nx/.cursor/agents/qa-test-expert.md +75 -0
  411. package/templates/frontend/angular-nx/.cursor/agents/security-auditor.md +61 -0
  412. package/templates/frontend/angular-nx/.cursor/hooks/auto-format.ts +70 -0
  413. package/templates/frontend/angular-nx/.cursor/hooks/auto-test-on-stop.ts +115 -0
  414. package/templates/frontend/angular-nx/.cursor/hooks/block-dangerous-commands.ts +188 -0
  415. package/templates/frontend/angular-nx/.cursor/hooks/ensure-tests-exist.ts +399 -0
  416. package/templates/frontend/angular-nx/.cursor/hooks/protect-sensitive-files.ts +128 -0
  417. package/templates/frontend/angular-nx/.cursor/hooks/session-context.ts +121 -0
  418. package/templates/frontend/angular-nx/.cursor/hooks.json +41 -0
  419. package/templates/frontend/react-vite/.cursor/agents/frontend-senior.agent.md +49 -49
  420. package/templates/frontend/react-vite/.cursor/agents/qa-test-expert.agent.md +126 -49
  421. package/templates/frontend/react-vite/.cursor/agents/security-expert.agent.md +39 -39
  422. package/templates/frontend/react-vite/.cursor/agents/ux-ui-expert.agent.md +45 -45
  423. package/templates/frontend/react-vite/.cursor/hooks/autoTestOnStop.ts +117 -0
  424. package/templates/frontend/react-vite/.cursor/hooks/blockDangerous.ts +75 -0
  425. package/templates/frontend/react-vite/.cursor/hooks/ensureTestsExist.ts +306 -220
  426. package/templates/frontend/react-vite/.cursor/hooks/formatOnEdit.ts +49 -0
  427. package/templates/frontend/react-vite/.cursor/hooks/protectSecrets.ts +88 -0
  428. package/templates/frontend/react-vite/.cursor/hooks/sessionInit.ts +77 -0
  429. package/templates/frontend/react-vite/.cursor/hooks.json +41 -10
  430. package/templates/frontend/react-vite/.cursor/settings.json +13 -13
  431. package/templates/frontend/react-vite/.vscode/settings.json +31 -31
  432. package/templates/frontend/react-vite/README.md +34 -34
  433. package/templates/frontend/react-vite/package.json +82 -82
  434. package/templates/frontend/react-vite/pnpm-lock.yaml +6575 -6575
  435. package/templates/frontend/react-vite/src/__tests__/components/layout/navbar.test.tsx +63 -0
  436. package/templates/frontend/react-vite/src/__tests__/components/ui/avatar.test.tsx +74 -0
  437. package/templates/frontend/react-vite/src/__tests__/components/ui/badge.test.tsx +55 -0
  438. package/templates/frontend/react-vite/src/__tests__/components/ui/breadcrumb.test.tsx +140 -0
  439. package/templates/frontend/react-vite/src/__tests__/components/ui/button.test.tsx +121 -0
  440. package/templates/frontend/react-vite/src/__tests__/components/ui/card.test.tsx +144 -0
  441. package/templates/frontend/react-vite/src/__tests__/components/ui/dialog.test.tsx +121 -0
  442. package/templates/frontend/react-vite/src/__tests__/components/ui/form.test.tsx +165 -0
  443. package/templates/frontend/react-vite/src/__tests__/components/ui/input.test.tsx +52 -0
  444. package/templates/frontend/react-vite/src/__tests__/components/ui/label.test.tsx +40 -0
  445. package/templates/frontend/react-vite/src/__tests__/components/ui/password-input.test.tsx +59 -0
  446. package/templates/frontend/react-vite/src/__tests__/components/ui/separator.test.tsx +40 -0
  447. package/templates/frontend/react-vite/src/__tests__/components/ui/table.test.tsx +254 -0
  448. package/templates/frontend/react-vite/src/__tests__/components/ui/tabs.test.tsx +82 -0
  449. package/templates/frontend/react-vite/src/__tests__/components/ui/textarea.test.tsx +47 -0
  450. package/templates/frontend/react-vite/src/__tests__/helpers/render.tsx +114 -0
  451. package/templates/frontend/react-vite/src/__tests__/hooks/useLocalStorage.test.ts +95 -0
  452. package/templates/frontend/react-vite/src/__tests__/lib/queryClient.test.ts +24 -0
  453. package/templates/frontend/react-vite/src/__tests__/lib/utils.test.ts +43 -0
  454. package/templates/frontend/react-vite/src/__tests__/routes/index.test.tsx +111 -0
  455. package/templates/frontend/react-vite/src/__tests__/routes/otra-ruta.test.tsx +126 -0
  456. package/templates/frontend/react-vite/src/__tests__/routes/root.test.tsx +78 -0
  457. package/templates/frontend/react-vite/src/__tests__/routes/ui-components.test.tsx +286 -0
  458. package/templates/frontend/react-vite/src/components/layout/navbar.tsx +38 -38
  459. package/templates/frontend/react-vite/src/components/ui/avatar.tsx +42 -42
  460. package/templates/frontend/react-vite/src/components/ui/dialog.tsx +122 -122
  461. package/templates/frontend/react-vite/src/components/ui/table.tsx +229 -244
  462. package/templates/frontend/react-vite/src/hooks/useLocalStorage.ts +32 -32
  463. package/templates/frontend/react-vite/src/routes/__root.tsx +48 -48
  464. package/templates/frontend/react-vite/src/routes/ui-components.tsx +359 -85
  465. package/templates/frontend/react-vite/src/test/setup.ts +24 -24
  466. package/templates/frontend/react-vite/vite.config.ts +2 -2
  467. package/templates/frontend/react-vite/vitest.config.ts +13 -2
@@ -0,0 +1,101 @@
1
+ import * as path from "node:path";
2
+
3
+ interface BeforeReadFilePayload {
4
+ file_path: string;
5
+ content: string;
6
+ workspace_roots: string[];
7
+ [key: string]: unknown;
8
+ }
9
+
10
+ function readStdin(): Promise<string> {
11
+ return new Promise((resolve) => {
12
+ let data = "";
13
+ process.stdin.setEncoding("utf8");
14
+ process.stdin.on("data", (chunk: string) => {
15
+ data += chunk;
16
+ });
17
+ process.stdin.on("end", () => resolve(data));
18
+ process.stdin.on("error", () => resolve(""));
19
+ });
20
+ }
21
+
22
+ function respond(output: Record<string, unknown>): void {
23
+ process.stdout.write(JSON.stringify(output) + "\n");
24
+ }
25
+
26
+ const ALLOWED_BASENAMES = new Set([".env.example"]);
27
+
28
+ const PROTECTED_BASENAMES = [
29
+ ".env",
30
+ ".env.local",
31
+ ".env.development",
32
+ ".env.production",
33
+ ".env.staging",
34
+ ".env.test",
35
+ "credentials.json",
36
+ "secrets.yaml",
37
+ "secrets.yml",
38
+ "id_rsa",
39
+ "id_ed25519",
40
+ ];
41
+
42
+ const PROTECTED_EXTENSIONS = [".pem", ".key", ".p12", ".pfx", ".jks"];
43
+
44
+ async function main(): Promise<void> {
45
+ try {
46
+ const raw = await readStdin();
47
+ if (!raw?.trim()) {
48
+ respond({ permission: "allow" });
49
+ return;
50
+ }
51
+
52
+ const payload = JSON.parse(
53
+ raw.replace(/^\uFEFF/, "").trim(),
54
+ ) as BeforeReadFilePayload;
55
+ const { file_path } = payload;
56
+ if (!file_path) {
57
+ respond({ permission: "allow" });
58
+ return;
59
+ }
60
+
61
+ const basename = path.basename(file_path);
62
+ const ext = path.extname(file_path);
63
+
64
+ if (ALLOWED_BASENAMES.has(basename)) {
65
+ respond({ permission: "allow" });
66
+ return;
67
+ }
68
+
69
+ if (PROTECTED_BASENAMES.includes(basename)) {
70
+ respond({
71
+ permission: "deny",
72
+ user_message: `Acceso bloqueado a ${basename}. Este archivo puede contener secretos (DB credentials, JWT_SECRET). Usá .env.example como referencia.`,
73
+ });
74
+ console.error(`[protectSecrets] Bloqueado: ${basename}`);
75
+ return;
76
+ }
77
+
78
+ if (PROTECTED_EXTENSIONS.includes(ext)) {
79
+ respond({
80
+ permission: "deny",
81
+ user_message: `Acceso bloqueado a ${basename}. Los archivos ${ext} pueden contener claves privadas.`,
82
+ });
83
+ console.error(`[protectSecrets] Bloqueado por extensión: ${basename}`);
84
+ return;
85
+ }
86
+
87
+ respond({ permission: "allow" });
88
+ } catch (err) {
89
+ console.error(
90
+ "[protectSecrets] Error:",
91
+ err instanceof Error ? err.message : String(err),
92
+ );
93
+ respond({
94
+ permission: "deny",
95
+ user_message:
96
+ "Hook de seguridad falló. Acceso bloqueado por precaución (fail-closed).",
97
+ });
98
+ }
99
+ }
100
+
101
+ main();
@@ -0,0 +1,104 @@
1
+ import { execSync } from "node:child_process";
2
+
3
+ interface SessionStartPayload {
4
+ session_id: string;
5
+ is_background_agent: boolean;
6
+ composer_mode: string;
7
+ workspace_roots: string[];
8
+ [key: string]: unknown;
9
+ }
10
+
11
+ function readStdin(): Promise<string> {
12
+ return new Promise((resolve) => {
13
+ let data = "";
14
+ process.stdin.setEncoding("utf8");
15
+ process.stdin.on("data", (chunk: string) => {
16
+ data += chunk;
17
+ });
18
+ process.stdin.on("end", () => resolve(data));
19
+ process.stdin.on("error", () => resolve(""));
20
+ });
21
+ }
22
+
23
+ function respond(output: Record<string, unknown>): void {
24
+ process.stdout.write(JSON.stringify(output) + "\n");
25
+ }
26
+
27
+ function run(cmd: string, cwd: string): string {
28
+ try {
29
+ return execSync(cmd, { cwd, timeout: 5000, encoding: "utf8" }).trim();
30
+ } catch {
31
+ return "unknown";
32
+ }
33
+ }
34
+
35
+ function isDockerRunning(cwd: string): string {
36
+ try {
37
+ const result = execSync(
38
+ 'docker compose ps --format "{{.Name}} {{.Status}}" 2>&1',
39
+ { cwd, timeout: 5000, encoding: "utf8" },
40
+ ).trim();
41
+ if (result.includes("Up")) return "running";
42
+ if (result) return "stopped";
43
+ return "no containers";
44
+ } catch {
45
+ return "docker not available";
46
+ }
47
+ }
48
+
49
+ async function main(): Promise<void> {
50
+ try {
51
+ const raw = await readStdin();
52
+ if (!raw?.trim()) {
53
+ respond({ continue: true });
54
+ return;
55
+ }
56
+
57
+ const payload = JSON.parse(
58
+ raw.replace(/^\uFEFF/, "").trim(),
59
+ ) as SessionStartPayload;
60
+ const cwd = payload.workspace_roots?.[0] ?? process.cwd();
61
+
62
+ const gitBranch = run("git rev-parse --abbrev-ref HEAD", cwd);
63
+ const nodeVersion = run("node --version", cwd);
64
+ const lastCommit = run('git log -1 --format="%h %s"', cwd);
65
+ const pnpmVersion = run("pnpm --version", cwd);
66
+ const dockerStatus = isDockerRunning(cwd);
67
+
68
+ const context = [
69
+ `Branch: ${gitBranch}`,
70
+ `Node: ${nodeVersion}`,
71
+ `pnpm: ${pnpmVersion}`,
72
+ `Último commit: ${lastCommit}`,
73
+ `Docker SQL Server: ${dockerStatus}`,
74
+ `Stack: NestJS 11 + Fastify 5 + Prisma 7 + SQL Server 2022 + Jest 30`,
75
+ `Tests unitarios en test/unit/, E2E en test/e2e/`,
76
+ `Formatter: Prettier (singleQuote, trailingComma: all)`,
77
+ `Linter: ESLint 9 + TypeScript + Prettier plugin`,
78
+ `ORM: Prisma con SQL Server (schema en prisma/schema.prisma)`,
79
+ ].join(". ");
80
+
81
+ respond({
82
+ env: {
83
+ GIT_BRANCH: gitBranch,
84
+ NODE_VERSION: nodeVersion,
85
+ PNPM_VERSION: pnpmVersion,
86
+ DOCKER_SQLSERVER_STATUS: dockerStatus,
87
+ },
88
+ additional_context: context,
89
+ continue: true,
90
+ });
91
+
92
+ console.error(
93
+ `[sessionInit] Branch: ${gitBranch}, Node: ${nodeVersion}, Docker: ${dockerStatus}`,
94
+ );
95
+ } catch (err) {
96
+ console.error(
97
+ "[sessionInit] Error:",
98
+ err instanceof Error ? err.message : String(err),
99
+ );
100
+ respond({ continue: true });
101
+ }
102
+ }
103
+
104
+ main();
@@ -0,0 +1,121 @@
1
+ interface BeforeShellPayload {
2
+ command: string;
3
+ cwd: string;
4
+ workspace_roots: string[];
5
+ [key: string]: unknown;
6
+ }
7
+
8
+ function readStdin(): Promise<string> {
9
+ return new Promise((resolve) => {
10
+ let data = "";
11
+ process.stdin.setEncoding("utf8");
12
+ process.stdin.on("data", (chunk: string) => {
13
+ data += chunk;
14
+ });
15
+ process.stdin.on("end", () => resolve(data));
16
+ process.stdin.on("error", () => resolve(""));
17
+ });
18
+ }
19
+
20
+ function respond(output: Record<string, unknown>): void {
21
+ process.stdout.write(JSON.stringify(output) + "\n");
22
+ }
23
+
24
+ const DENY_PATTERNS: Array<{ pattern: RegExp; label: string }> = [
25
+ {
26
+ pattern: /prisma\s+migrate\s+reset/,
27
+ label: "prisma migrate reset (destruye todos los datos de SQL Server)",
28
+ },
29
+ {
30
+ pattern: /prisma\s+db\s+push\s+--force-reset/,
31
+ label: "prisma db push --force-reset (recrea la DB desde cero)",
32
+ },
33
+ {
34
+ pattern: /prisma\s+db\s+execute/,
35
+ label: "prisma db execute (SQL arbitrario contra la DB)",
36
+ },
37
+ ];
38
+
39
+ const ASK_PATTERNS: Array<{ pattern: RegExp; label: string }> = [
40
+ {
41
+ pattern: /prisma\s+migrate\s+dev/,
42
+ label: "prisma migrate dev (puede modificar el schema de SQL Server)",
43
+ },
44
+ {
45
+ pattern: /prisma\s+db\s+push(?!\s+--force-reset)/,
46
+ label: "prisma db push (sincroniza schema sin migraciones)",
47
+ },
48
+ {
49
+ pattern: /prisma\s+db\s+seed/,
50
+ label: "prisma db seed (ejecuta el script de seed)",
51
+ },
52
+ ];
53
+
54
+ const SAFE_PATTERNS: RegExp[] = [
55
+ /prisma\s+generate/,
56
+ /prisma\s+studio/,
57
+ /prisma\s+format/,
58
+ /prisma\s+validate/,
59
+ /prisma\s+--version/,
60
+ /prisma\s+--help/,
61
+ /prisma\s+init/,
62
+ ];
63
+
64
+ async function main(): Promise<void> {
65
+ try {
66
+ const raw = await readStdin();
67
+ if (!raw?.trim()) {
68
+ respond({ permission: "allow" });
69
+ return;
70
+ }
71
+
72
+ const payload = JSON.parse(
73
+ raw.replace(/^\uFEFF/, "").trim(),
74
+ ) as BeforeShellPayload;
75
+ const { command } = payload;
76
+ if (!command) {
77
+ respond({ permission: "allow" });
78
+ return;
79
+ }
80
+
81
+ for (const safe of SAFE_PATTERNS) {
82
+ if (safe.test(command)) {
83
+ respond({ permission: "allow" });
84
+ return;
85
+ }
86
+ }
87
+
88
+ for (const { pattern, label } of DENY_PATTERNS) {
89
+ if (pattern.test(command)) {
90
+ respond({
91
+ permission: "deny",
92
+ user_message: `Comando Prisma bloqueado: ${label}`,
93
+ agent_message: `El comando '${command}' fue bloqueado porque es destructivo ('${label}'). Si realmente necesitás ejecutarlo, pedile al usuario que lo haga manualmente en la terminal.`,
94
+ });
95
+ console.error(`[validatePrisma] Bloqueado: ${label}`);
96
+ return;
97
+ }
98
+ }
99
+
100
+ for (const { pattern, label } of ASK_PATTERNS) {
101
+ if (pattern.test(command)) {
102
+ respond({
103
+ permission: "ask",
104
+ user_message: `Comando Prisma requiere confirmación: ${label}`,
105
+ });
106
+ console.error(`[validatePrisma] Requiere confirmación: ${label}`);
107
+ return;
108
+ }
109
+ }
110
+
111
+ respond({ permission: "allow" });
112
+ } catch (err) {
113
+ console.error(
114
+ "[validatePrisma] Error:",
115
+ err instanceof Error ? err.message : String(err),
116
+ );
117
+ respond({ permission: "allow" });
118
+ }
119
+ }
120
+
121
+ main();
@@ -0,0 +1,46 @@
1
+ {
2
+ "version": 1,
3
+ "hooks": {
4
+ "sessionStart": [
5
+ {
6
+ "command": "npx tsx .cursor/hooks/sessionInit.ts",
7
+ "timeout": 15
8
+ }
9
+ ],
10
+ "afterFileEdit": [
11
+ {
12
+ "command": "npx tsx .cursor/hooks/ensureTestsExist.ts",
13
+ "timeout": 15
14
+ },
15
+ {
16
+ "command": "npx tsx .cursor/hooks/formatOnEdit.ts",
17
+ "timeout": 10
18
+ }
19
+ ],
20
+ "beforeShellExecution": [
21
+ {
22
+ "command": "npx tsx .cursor/hooks/blockDangerous.ts",
23
+ "matcher": "rm|del|rmdir|drop|truncate|format|mkfs|Remove-Item",
24
+ "timeout": 5
25
+ },
26
+ {
27
+ "command": "npx tsx .cursor/hooks/validatePrisma.ts",
28
+ "matcher": "prisma",
29
+ "timeout": 5
30
+ }
31
+ ],
32
+ "beforeReadFile": [
33
+ {
34
+ "command": "npx tsx .cursor/hooks/protectSecrets.ts",
35
+ "timeout": 5
36
+ }
37
+ ],
38
+ "stop": [
39
+ {
40
+ "command": "npx tsx .cursor/hooks/autoTestOnStop.ts",
41
+ "timeout": 10,
42
+ "loop_limit": 2
43
+ }
44
+ ]
45
+ }
46
+ }
@@ -0,0 +1,126 @@
1
+ ---
2
+ description: REST API architecture and technical standards for modern TypeScript applications
3
+ alwaysApply: true
4
+ ---
5
+
6
+ # REST API - Architecture & Standards
7
+
8
+ ## Primary Goal
9
+
10
+ Build **production-ready, scalable REST APIs** using modern TypeScript technologies with enterprise-grade quality, security, and maintainability.
11
+
12
+ ## Core Technical Stack
13
+
14
+ ### Backend Framework
15
+ - **NestJS 11**: Progressive Node.js framework with TypeScript-first approach
16
+ - **Fastify**: High-performance HTTP server optimized for speed
17
+ - **TypeScript**: Strict type safety throughout the application
18
+
19
+ ### Data Layer
20
+ - **Prisma ORM**: Type-safe database access with excellent developer experience
21
+ - **SQL Server Database**: Use SQL Server for all environments (dev via Docker, production via hosted service)
22
+ - **Migration system**: Version-controlled database schema changes
23
+
24
+ ### Security & Authentication
25
+ - **JWT Authentication**: Stateless token-based authentication
26
+ - **Role-Based Access Control (RBAC)**: Granular permission system
27
+ - **Password Security**: bcrypt hashing, secure credential storage
28
+
29
+ ## Architecture Principles
30
+
31
+ ### 1. Modular Design
32
+ - **Feature-based modules**: Each domain (auth, users, posts) in isolated modules
33
+ - **Clear boundaries**: Well-defined interfaces between modules
34
+ - **Dependency injection**: Loose coupling, easy testing
35
+ - **Single Responsibility**: Each module handles one domain concern
36
+
37
+ ### 2. Layered Architecture
38
+ ```
39
+ Controllers (HTTP Layer)
40
+ ↓
41
+ Services (Business Logic)
42
+ ↓
43
+ Repositories/Prisma (Data Access)
44
+ ```
45
+
46
+ ### 3. Type Safety & Validation
47
+ - **End-to-end TypeScript**: From request to database to response
48
+ - **DTOs with decorators**: class-validator for automatic validation
49
+ - **Prisma types**: Auto-generated, type-safe database models
50
+ - **No implicit any**: Strict TypeScript configuration
51
+
52
+ ### 4. API Documentation
53
+ - **Swagger/OpenAPI**: Auto-generated, always up-to-date
54
+ - **Decorator-based**: Documentation as code (@ApiProperty, @ApiOperation)
55
+ - **Interactive UI**: Available at `/docs` endpoint
56
+ - **Schema validation**: DTO definitions visible in Swagger
57
+
58
+ ### 5. Security by Design
59
+ - **Protected by default**: All endpoints require authentication unless explicitly public
60
+ - **JWT Guards**: Automatic token validation
61
+ - **CORS configuration**: Secure cross-origin policies
62
+ - **Input validation**: All incoming data validated against DTOs
63
+ - **Error sanitization**: No sensitive data in error responses
64
+
65
+ ## Development Standards
66
+
67
+ ### Code Quality
68
+ - **ESLint**: Enforced coding standards
69
+ - **Prettier**: Consistent code formatting
70
+ - **Type safety**: No `any` types without explicit justification
71
+ - **Error handling**: Proper try-catch blocks with typed errors
72
+
73
+ ### Database Practices
74
+ - **Migrations**: All schema changes through Prisma migrations
75
+ - **Seeding**: Automated test data creation for development
76
+ - **Relations**: Proper foreign keys and cascade rules
77
+ - **Indexes**: Performance-optimized queries
78
+
79
+ ### API Design
80
+ - **RESTful conventions**: Standard HTTP methods (GET, POST, PATCH, DELETE)
81
+ - **HTTP status codes**: Semantic response codes (200, 201, 400, 401, 404, etc.)
82
+ - **Consistent naming**: kebab-case for URLs, camelCase for JSON
83
+ - **Versioning ready**: API structure prepared for future versions
84
+
85
+ ### Developer Experience
86
+ - **Hot reload**: Fast development cycle with watch mode
87
+ - **Auto-seeding**: Pre-populated test data on startup
88
+ - **Health checks**: `/health` endpoint for monitoring
89
+ - **Clear error messages**: Helpful validation errors
90
+
91
+ ## Production Readiness
92
+
93
+ ### Performance
94
+ - **Fastify speed**: High-throughput HTTP handling
95
+ - **Prisma optimization**: Efficient database queries
96
+ - **Connection pooling**: Managed database connections
97
+ - **Async operations**: Non-blocking I/O throughout
98
+
99
+ ### Scalability
100
+ - **Stateless design**: Horizontal scaling capable
101
+ - **Database flexibility**: Easy migration to production databases
102
+ - **Modular growth**: New features as independent modules
103
+ - **Resource efficiency**: Optimized memory and CPU usage
104
+
105
+ ### Monitoring & Debugging
106
+ - **Logging**: Structured application logs
107
+ - **Error tracking**: Proper error propagation and handling
108
+ - **Health endpoints**: System status monitoring
109
+ - **Swagger docs**: Runtime API exploration
110
+
111
+ ### Testing
112
+ - **Jest framework**: Unit and integration tests
113
+ - **E2E testing**: Full request-response cycle tests
114
+ - **Test coverage**: Comprehensive test suite capability
115
+ - **Mocking support**: Easy dependency mocking
116
+
117
+ ## Quality Standards
118
+
119
+ ✅ **Type Safety**: 100% TypeScript coverage, no implicit any
120
+ ✅ **Validation**: All inputs validated with class-validator
121
+ ✅ **Documentation**: All endpoints documented in Swagger
122
+ ✅ **Security**: Authentication, authorization, input sanitization
123
+ ✅ **Error Handling**: Proper HTTP codes and error responses
124
+ ✅ **Code Quality**: ESLint/Prettier compliance
125
+ ✅ **Database Integrity**: Migrations, relations, constraints
126
+ ✅ **Performance**: Fastify optimizations, efficient queries
@@ -0,0 +1,86 @@
1
+ ---
2
+ description: JWT authentication and security patterns
3
+ globs: src/auth/**/*.ts
4
+ alwaysApply: false
5
+ ---
6
+
7
+ # Authentication & Security Standards
8
+
9
+ ## JWT Guard Protection
10
+
11
+ Protected endpoints MUST use `@UseGuards(JwtAuthGuard)`:
12
+
13
+ ```typescript
14
+ // ❌ BAD - Unprotected endpoint
15
+ @Get('me')
16
+ async getCurrentUser(@Request() req) {
17
+ return req.user;
18
+ }
19
+
20
+ // ✅ GOOD - Protected with JWT
21
+ @UseGuards(JwtAuthGuard)
22
+ @ApiBearerAuth('JWT-auth')
23
+ @Get('me')
24
+ async getCurrentUser(@Request() req) {
25
+ return req.user;
26
+ }
27
+ ```
28
+
29
+ ## Swagger Security Documentation
30
+
31
+ Protected endpoints MUST be marked with `@ApiBearerAuth()`:
32
+
33
+ ```typescript
34
+ @UseGuards(JwtAuthGuard)
35
+ @ApiBearerAuth('JWT-auth') // Required for Swagger
36
+ @Get('protected')
37
+ async protectedRoute() {
38
+ // ...
39
+ }
40
+ ```
41
+
42
+ ## Password Handling
43
+
44
+ - Never return passwords in responses
45
+ - Always hash passwords before storing
46
+ - Use bcrypt or similar for hashing
47
+
48
+ ```typescript
49
+ // ❌ BAD - Plain text password
50
+ const user = await this.prisma.user.create({
51
+ data: { password: dto.password }
52
+ });
53
+
54
+ // ✅ GOOD - Hashed password
55
+ const hashedPassword = await bcrypt.hash(dto.password, 10);
56
+ const user = await this.prisma.user.create({
57
+ data: { password: hashedPassword }
58
+ });
59
+ ```
60
+
61
+ ## User Context
62
+
63
+ Access authenticated user from request:
64
+
65
+ ```typescript
66
+ @UseGuards(JwtAuthGuard)
67
+ @Get('me')
68
+ async getCurrentUser(@Request() req) {
69
+ // req.user is populated by JWT strategy
70
+ const userId = req.user.userId;
71
+ return this.usersService.findOne(userId);
72
+ }
73
+ ```
74
+
75
+ ## Public Endpoints
76
+
77
+ Public endpoints should NOT have `@UseGuards()`:
78
+
79
+ ```typescript
80
+ // ✅ GOOD - Public endpoint
81
+ @Post('login')
82
+ @ApiTags('Authentication')
83
+ async login(@Body() dto: LoginDto) {
84
+ return this.authService.login(dto);
85
+ }
86
+ ```
@@ -0,0 +1,93 @@
1
+ ---
2
+ description: DTO validation and Swagger documentation standards
3
+ globs: src/**/dto/*.ts
4
+ alwaysApply: false
5
+ ---
6
+
7
+ # DTO Validation & Documentation
8
+
9
+ ## Required Decorators
10
+
11
+ Every DTO MUST have both validation (`class-validator`) and documentation (`@nestjs/swagger`):
12
+
13
+ ```typescript
14
+ // ❌ BAD - Missing decorators
15
+ export class CreatePostDto {
16
+ title: string;
17
+ content: string;
18
+ }
19
+
20
+ // ✅ GOOD - Full validation + documentation
21
+ import { IsString, IsNotEmpty, MaxLength } from 'class-validator';
22
+ import { ApiProperty } from '@nestjs/swagger';
23
+
24
+ export class CreatePostDto {
25
+ @ApiProperty({
26
+ description: 'The title of the post',
27
+ example: 'My First Post',
28
+ maxLength: 255,
29
+ })
30
+ @IsString()
31
+ @IsNotEmpty()
32
+ @MaxLength(255)
33
+ title: string;
34
+
35
+ @ApiProperty({
36
+ description: 'The content of the post',
37
+ example: 'This is the content...',
38
+ })
39
+ @IsString()
40
+ @IsNotEmpty()
41
+ content: string;
42
+ }
43
+ ```
44
+
45
+ ## Optional Fields
46
+
47
+ Use `@IsOptional()` for optional fields:
48
+
49
+ ```typescript
50
+ @ApiProperty({ required: false })
51
+ @IsOptional()
52
+ @IsString()
53
+ name?: string;
54
+ ```
55
+
56
+ ## Enums
57
+
58
+ Document enum values explicitly:
59
+
60
+ ```typescript
61
+ @ApiProperty({
62
+ enum: ['light', 'dark', 'auto'],
63
+ example: 'dark',
64
+ })
65
+ @IsEnum(['light', 'dark', 'auto'])
66
+ theme: string;
67
+ ```
68
+
69
+ ## Response DTOs
70
+
71
+ Create dedicated response DTOs without validation decorators:
72
+
73
+ ```typescript
74
+ export class UserResponseDto {
75
+ @ApiProperty({ example: 1 })
76
+ id: number;
77
+
78
+ @ApiProperty({ example: 'user@example.com' })
79
+ email: string;
80
+
81
+ // ❌ Don't include password in responses
82
+ }
83
+ ```
84
+
85
+ ## Partial Updates
86
+
87
+ Use `@nestjs/swagger`'s `PartialType` for update DTOs:
88
+
89
+ ```typescript
90
+ import { PartialType } from '@nestjs/swagger';
91
+
92
+ export class UpdatePostDto extends PartialType(CreatePostDto) {}
93
+ ```