You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+2-10Lines changed: 2 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -290,13 +290,5 @@ APIs:
290
290
291
291
Snapshots are optional; if you don’t provide them, itemsjs rebuilds indexes as before.
292
292
293
-
Benchmark (Node):
294
-
- Run `npm run benchmark:snapshot` to compare fresh build vs snapshot load (defaults to 1k, 10k and 30k items). Override sizes with `SIZES=5000,20000 npm run benchmark:snapshot`.
295
-
- Output includes cold-start speedup ratio (build/load). Note: real-world cost in browser also includes `fetch` + `JSON.parse` time if you download the snapshot.
296
-
297
-
Search benchmark (Node):
298
-
- Run `npm run benchmark:search` to measure build/search/facets timings across scenarios (empty, query-only, filters-only, query+filters, boolean filter). Defaults to sizes 1k/10k/30k; override with `SIZES=5000,20000` and repeats with `REPEAT=10`.
299
-
300
-
Browser smoke test (manual/optional):
301
-
- Build the bundle: `npm run build`.
302
-
- EITHER open `benchmarks/browser-snapshot.html` directly in a browser, OR run `npm run serve:benchmark` and open `http://localhost:4173/` (auto-loads the snapshot page). It builds once, saves a snapshot to `localStorage`, and on refresh loads from it and logs a sample search.
293
+
Benchmarks and browser smoke test:
294
+
- See `docs/benchmarks.md` for snapshot/search benchmarks and the optional browser smoke test.
- Defaults: sizes `1000,10000,30000`, repeats per scenario `5`.
20
+
- Override: `SIZES=5000,20000`, `REPEAT=10`.
21
+
- Dataset per size: 40 tags, 30 actors, 4 categories, boolean `popular`; each item has 3 tags, 1 actor, 1 category. Facets: tags, actors, category, popular. Searchable fields: name (boosted), tags, actors.
22
+
- Stress facet-heavy setups with `EXTRA_FACETS=1000` (each with 3 values) to see scaling for many facets.
23
+
24
+
## Browser smoke test
25
+
26
+
- Build: `npm run build`.
27
+
- Run: `npm run serve:benchmark` and open `http://localhost:4173/` (serves `benchmarks/browser-snapshot.html`), or open the HTML directly.
28
+
- First load builds and stores a snapshot in `localStorage`; subsequent loads use the snapshot and log a sample search. Green message = OK; red/error or stuck on “Loading…” → check console.
0 commit comments