vue-feat-cli 26.9.0 → 26.9.2

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 (3) hide show
  1. package/README.md +47 -2
  2. package/dist/cli.js +932 -288
  3. package/package.json +9 -1
package/README.md CHANGED
@@ -61,12 +61,15 @@ Produces `vf.config.json`:
61
61
  "httpClient": "fetch",
62
62
  "usesPinia": true,
63
63
  "usesVueRouter": true,
64
- "usesTanstackQuery": false
64
+ "usesTanstackQuery": false,
65
+ "layers": { "store": true }
65
66
  }
66
67
  ```
67
68
 
68
69
  All subsequent generators read this file. If it doesn't exist, safe defaults are used (`fetch`, no Pinia, no Router).
69
70
 
71
+ `layers` is optional — set any of `service, serviceComposable, pageComposable, store, types, index, routes, view` to `false` to disable it by default (re-enable per-run with `--only`).
72
+
70
73
  ---
71
74
 
72
75
  ### `g:feat <name>`
@@ -99,6 +102,27 @@ src/features/product/
99
102
 
100
103
  Without Vue Router, `routes.ts` and `views/` are omitted and a blank `views/` folder is created instead.
101
104
 
105
+ #### Partial generation (layers)
106
+
107
+ ```bash
108
+ vf g:feat Billing --only service,store # only these layers
109
+ vf g:feat Billing --exclude view,routes # everything except
110
+ vf g:feat Billing --no-store --no-types # convenience negations
111
+ # also: --no-service --no-composables --no-view --no-routes --no-index
112
+ ```
113
+
114
+ Layer names: `service, serviceComposable, pageComposable, store, types, index, routes, view` (`composables` = both composables).
115
+
116
+ #### Headless / agent-friendly flags (all generators)
117
+
118
+ ```bash
119
+ vf g:feat Product --dry-run --json # preview without writing, pure-JSON stdout
120
+ vf g:feat Product --json # write + emit { ok, files[], warnings[] }
121
+ vf g:feat Product --force --json # overwrite existing files
122
+ ```
123
+
124
+ In `--json` mode stdout is parseable JSON only — warnings go into `warnings[]`, per-file results into `files[]` (`created | overwritten | skipped | dry-run | exists`). Exit code is `1` on failure.
125
+
102
126
  ---
103
127
 
104
128
  ### `g:composable <name>`
@@ -143,10 +167,31 @@ vf g:store product --feature product
143
167
 
144
168
  ---
145
169
 
170
+ ### `doctor`
171
+
172
+ Diagnoses config, directories, tsconfig alias, deps vs config, http client and router. Also lists built-in templates + variable names.
173
+
174
+ ```bash
175
+ vf doctor # human-readable
176
+ vf doctor --json # machine-readable (run this first in agents/CI)
177
+ ```
178
+
179
+ ---
180
+
181
+ ### `agents:init`
182
+
183
+ Generates `AGENTS.md` at the project root with stack, layering rules and the CLI contract. Commit it so every agent follows the same conventions.
184
+
185
+ ```bash
186
+ vf agents:init
187
+ vf agents:init --force # regenerate after changing vf.config.json
188
+ ```
189
+
190
+ ---
191
+
146
192
  ## Architecture
147
193
 
148
194
  Each feature follows a strict layered separation:
149
-
150
195
  ```
151
196
  service.ts
152
197
  └── useXxxService.ts ← business composable: data refs + CRUD, no UI state