@teispace/next-maker 1.12.0 → 1.13.0

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.13.0](https://github.com/teispace/npm-packages/compare/next-maker-v1.12.0...next-maker-v1.13.0) (2026-04-02)
4
+
5
+
6
+ ### Features
7
+
8
+ * **next-maker:** split CRUD response types into Summary and Detail ([a02fdc8](https://github.com/teispace/npm-packages/commit/a02fdc863b67d9dd370c94402deb0ebfa199526c))
9
+
3
10
  ## [1.12.0](https://github.com/teispace/npm-packages/compare/next-maker-v1.11.2...next-maker-v1.12.0) (2026-04-02)
4
11
 
5
12
 
package/README.md CHANGED
@@ -255,7 +255,8 @@ npx @teispace/next-maker service <name> [options]
255
255
  **CRUD mode** generates:
256
256
 
257
257
  - Service with 5 methods: `getAll`, `getById`, `create`, `update`, `delete`
258
- - DTO types: `Create<Name>Dto`, `Update<Name>Dto`, `<Name>` response interface
258
+ - `<Name>Summary` type for list responses (cards, tables) and `<Name>Detail` type for single-item responses (detail pages)
259
+ - DTO types: `Create<Name>Dto`, `Update<Name>Dto`
259
260
  - Full API config with dynamic routes (`getById(id)`, `update(id)`, `delete(id)`)
260
261
 
261
262
  **Examples:**
@@ -303,6 +304,31 @@ npx @teispace/next-maker locale fr --copy-translations
303
304
 
304
305
  ---
305
306
 
307
+ ### 9. Generate a Hook
308
+
309
+ Create a custom React hook with loading/error state boilerplate.
310
+
311
+ ```bash
312
+ npx @teispace/next-maker hook <name> [options]
313
+ ```
314
+
315
+ **Options:**
316
+
317
+ - `--client` - Add `'use client'` directive (default: true)
318
+ - `--feature <path>` - Generate in feature directory
319
+
320
+ **Examples:**
321
+
322
+ ```bash
323
+ # Shared hook in src/hooks/
324
+ npx @teispace/next-maker hook auth-session
325
+
326
+ # Hook inside a feature
327
+ npx @teispace/next-maker hook user-profile --feature src/features/auth
328
+ ```
329
+
330
+ ---
331
+
306
332
  ## Usage Examples
307
333
 
308
334
  ### Quick Start - New Project
@@ -363,7 +389,7 @@ Creates component in `src/components/common/<Name>/` and auto-updates all barrel
363
389
 
364
390
  ### CRUD Service Generation
365
391
 
366
- `--crud` flag generates a complete service with 5 REST methods, typed DTOs, and full API config with dynamic route helpers.
392
+ `--crud` flag generates a complete service with 5 REST methods, separate `Summary` and `Detail` response types (list vs detail views), typed DTOs, and full API config with dynamic route helpers.
367
393
 
368
394
  ### Locale Management
369
395
 
@@ -407,6 +433,7 @@ All commands support `--path` for custom locations. Relative paths like `feature
407
433
  | `slice <name>` | Generate a Redux slice |
408
434
  | `service <name>` | Generate an API service |
409
435
  | `locale [code]` | Add a new locale/language |
436
+ | `hook <name>` | Generate a custom React hook |
410
437
 
411
438
  ---
412
439