citadel_cli 1.3.0 → 1.4.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/README.md CHANGED
@@ -165,11 +165,11 @@ const config = {
165
165
  commandTimeoutMs: 10000,
166
166
  includeHelpCommand: true,
167
167
  fontFamily: '"JetBrains Mono", monospace',
168
- fontSize: '0.875rem', // CSS size (e.g. '14px') or Tailwind class (e.g. 'text-sm')
168
+ fontSize: '0.875rem', // CSS font-size value (e.g. '14px', '0.875rem')
169
169
  maxHeight: '80vh',
170
- initialHeight: '40vh',
170
+ initialHeight: '50vh',
171
171
  minHeight: '200',
172
- outputFontSize: 'text-xs', // optional override for output text only
172
+ outputFontSize: '0.75rem', // optional CSS font-size override for output text
173
173
  resetStateOnHide: false,
174
174
  showCitadelKey: '.',
175
175
  cursorType: 'blink', // 'blink', 'spin', 'solid', or 'bbs'
@@ -187,6 +187,64 @@ Then to make the component aware of them:
187
187
  <Citadel commandRegistry={cmdRegistry} config={config} />
188
188
  ```
189
189
 
190
+ ## Performance Metrics
191
+
192
+ Citadel includes scripts to capture and compare before/after performance and
193
+ size metrics.
194
+
195
+ ### Metrics collected
196
+
197
+ - Build metrics:
198
+ - Bundle size (raw + gzip) for `dist/citadel.es.js`, `dist/citadel.umd.cjs`,
199
+ and `dist/citadel.css`
200
+ - Total LOC and extension breakdown
201
+ - Dependency presence for `tailwindcss`, `postcss`, and `autoprefixer`
202
+ - `node_modules` size (`du -sk`)
203
+ - Runtime metrics (Chromium):
204
+ - JS heap usage before/after interaction
205
+ - Input latency (keydown to input update)
206
+ - FPS sample over a short window
207
+ - Long task count and duration
208
+ - DOM node count
209
+
210
+ All outputs are written to `test-results/metrics/`.
211
+
212
+ ### Commands
213
+
214
+ ```bash
215
+ npm run metrics:build
216
+ npm run metrics:runtime
217
+ npm run metrics:compare -- --before <before.json> --after <after.json>
218
+ npm run metrics:all -- --label <label>
219
+ npm run metrics:report -- --label <label> --before-build <before-build.json> --before-runtime <before-runtime.json>
220
+ ```
221
+
222
+ ### Before/After workflow
223
+
224
+ 1. Capture a baseline snapshot:
225
+
226
+ ```bash
227
+ npm run metrics:all -- --label before
228
+ ```
229
+
230
+ 2. After your changes, capture the new snapshot and generate comparisons:
231
+
232
+ ```bash
233
+ npm run metrics:all -- --label after \
234
+ --before-build test-results/metrics/build-before-<timestamp>.json \
235
+ --before-runtime test-results/metrics/runtime-before-<timestamp>.json
236
+ ```
237
+
238
+ 3. Open generated reports:
239
+ - `test-results/metrics/run-after.md`
240
+ - `test-results/metrics/compare-build-after.md` (if `--before-build` provided)
241
+ - `test-results/metrics/compare-runtime-after.md` (if `--before-runtime` provided)
242
+
243
+ Notes:
244
+ - `metrics:runtime` starts a local dev server and requires local port binding.
245
+ - If you only want comparison output from existing snapshots, use
246
+ `npm run metrics:report`.
247
+
190
248
  ## Contributing
191
249
 
192
250
  See [CONTRIBUTING.md](./CONTRIBUTING.md) for guidelines on developing, testing, and releasing Citadel CLI.
@@ -4,9 +4,5 @@
4
4
  "name": "index",
5
5
  "src": "src/index.ts",
6
6
  "isEntry": true
7
- },
8
- "style.css": {
9
- "file": "citadel.css",
10
- "src": "style.css"
11
7
  }
12
8
  }