@ipxjs/refract 0.10.0 → 0.10.1

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 (2) hide show
  1. package/README.md +32 -29
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -224,22 +224,22 @@ The values below are from a local run on February 17, 2026.
224
224
 
225
225
  | Framework | JS bundle (raw) | JS bundle (gzip) |
226
226
  |---------------------------|----------------:|-----------------:|
227
- | Refract (`core`) | 8.62 kB | 3.24 kB |
228
- | Refract (`core+hooks`) | 10.27 kB | 3.84 kB |
229
- | Refract (`core+context`) | 9.12 kB | 3.47 kB |
230
- | Refract (`core+memo`) | 9.29 kB | 3.47 kB |
231
- | Refract (`core+security`) | 9.53 kB | 3.54 kB |
232
- | Refract (`refract`) | 15.20 kB | 5.55 kB |
233
- | React | 189.74 kB | 59.58 kB |
234
- | Preact | 14.46 kB | 5.96 kB |
227
+ | Refract (`core`) | 10.02 kB | 3.74 kB |
228
+ | Refract (`core+hooks`) | 12.08 kB | 4.49 kB |
229
+ | Refract (`core+context`) | 10.66 kB | 4.00 kB |
230
+ | Refract (`core+memo`) | 10.70 kB | 3.97 kB |
231
+ | Refract (`core+security`) | 10.93 kB | 4.03 kB |
232
+ | Refract (`refract`) | 17.15 kB | 6.23 kB |
233
+ | React | 189.74 kB | 59.52 kB |
234
+ | Preact | 14.46 kB | 5.95 kB |
235
235
 
236
236
  Load-time metrics are machine-dependent, so the benchmark script prints a fresh
237
237
  per-run timing table (median, p95, min/max, sd) for every framework.
238
- The CI preset (`make bench-ci`, 40 measured + 5 warmup runs) also passed on
239
- February 17, 2026 with default guardrails (`DCL p95 <= 16ms`, `DCL sd <= 2ms`).
238
+ The CI preset (`make bench-ci`, 40 measured + 5 warmup runs) enforces default
239
+ guardrails (`DCL p95 <= 16ms`, `DCL sd <= 2ms`).
240
240
 
241
- From this snapshot, Refract `core` gzip JS is about 18.4x smaller than React,
242
- and the full `refract` entrypoint is about 10.7x smaller.
241
+ From this snapshot, Refract `core` gzip JS is about 15.9x smaller than React,
242
+ and the full `refract` entrypoint is about 9.6x smaller.
243
243
 
244
244
  ### Component Combination Benchmarks (Vitest)
245
245
 
@@ -249,15 +249,15 @@ Higher `hz` is better.
249
249
 
250
250
  | Component usage profile | Mount (hz) | Mount vs base | Reconcile (hz) | Reconcile vs base |
251
251
  |-------------------------|------------|---------------|----------------|-------------------|
252
- | `base` | 6570.25 | baseline | 3413.29 | baseline |
253
- | `memo` | 7257.38 | +10.5% | 7541.91 | +120.9% |
254
- | `context` | 6427.45 | -2.2% | 7119.35 | +108.6% |
255
- | `fragment` | 5935.06 | -9.7% | 3437.54 | +0.7% |
256
- | `keyed` | 9022.55 | +37.3% | 6535.55 | +91.5% |
257
- | `memo+context` | 7015.37 | +6.8% | 6782.87 | +98.7% |
258
- | `memo+context+keyed` | 7992.82 | +21.7% | 6803.09 | +99.3% |
259
-
260
- In this run, `keyed` was the fastest mount profile, while
252
+ | `base` | 5160.53 | baseline | 3262.99 | baseline |
253
+ | `memo` | 4858.51 | -5.9% | 5092.55 | +56.1% |
254
+ | `context` | 3862.01 | -25.2% | 4954.24 | +51.8% |
255
+ | `fragment` | 4656.36 | -9.8% | 3760.97 | +15.3% |
256
+ | `keyed` | 5754.75 | +11.5% | 4311.45 | +32.1% |
257
+ | `memo+context` | 5872.59 | +13.8% | 4621.45 | +41.6% |
258
+ | `memo+context+keyed` | 5555.42 | +7.7% | 4509.78 | +38.2% |
259
+
260
+ In this run, `memo+context` was the fastest mount profile, while
261
261
  `memo` was the fastest reconcile profile.
262
262
 
263
263
  ### Running the Benchmark
@@ -304,7 +304,7 @@ How Refract compares to React and Preact:
304
304
  | SVG support | Yes | Yes | Yes |
305
305
  | **Components** | | | |
306
306
  | Functional components | Yes | Yes | Yes |
307
- | Class components | No | Yes | Yes |
307
+ | Class components | Partial⁶ | Yes | Yes |
308
308
  | **Hooks** | | | |
309
309
  | useState | Yes | Yes | Yes |
310
310
  | useEffect | Yes | Yes | Yes |
@@ -329,10 +329,10 @@ How Refract compares to React and Preact:
329
329
  | className prop | Yes | Yes | Yes¹ |
330
330
  | dangerouslySetInnerHTML | Yes | Yes | Yes |
331
331
  | Portals | Yes | Yes | Yes |
332
- | Suspense / lazy | No | Yes | Yes² |
332
+ | Suspense / lazy | No| Yes | Yes² |
333
333
  | Error boundaries | Yes³ | Yes | Yes |
334
334
  | Server-side rendering | No | Yes | Yes |
335
- | Hydration | No | Yes | Yes |
335
+ | Hydration | No| Yes | Yes |
336
336
  | **Security** | | | |
337
337
  | Default HTML sanitizer for `dangerouslySetInnerHTML` | Yes | No | No |
338
338
  | Configurable HTML sanitizer hook (`setHtmlSanitizer`) | Yes | No | No |
@@ -340,19 +340,22 @@ How Refract compares to React and Preact:
340
340
  | Fiber architecture | Yes | Yes | No |
341
341
  | Concurrent rendering | No | Yes | No |
342
342
  | Automatic batching | Yes | Yes | Yes |
343
- | memo / PureComponent | Yes | Yes | Yes |
343
+ | memo / PureComponent | Partial¹⁰ | Yes | Yes |
344
344
  | **Ecosystem** | | | |
345
345
  | DevTools | Basic (hook API) | Yes | Yes |
346
- | React compatibility layer | Yes | N/A | Yes⁷ |
347
- | **Bundle Size (gzip, JS)** | ~3.2-5.6 kB⁴ | ~59.5 kB | ~6.0 kB |
346
+ | React compatibility layer | Partial | N/A | Yes⁷ |
347
+ | **Bundle Size (gzip, JS)** | ~3.7-6.3 kB⁴ | ~59.5 kB | ~6.0 kB |
348
348
 
349
349
  ¹ Preact supports both `class` and `className`.
350
350
  ² Preact has partial Suspense support via `preact/compat`.
351
- ³ Refract uses the `useErrorBoundary` hook rather than class-based error boundaries.
351
+ ³ Refract core uses the `useErrorBoundary` hook; compat wrappers can emulate class-style boundaries.
352
352
  ⁴ Refract size depends on entrypoint (`refract/core` vs `refract` full).
353
353
  ⁵ Refract exposes `useTransition` / `useDeferredValue` but currently runs both synchronously (no concurrent scheduling).
354
- ⁶ Available via opt-in compat entrypoints (`refract/compat/react*`).
354
+ ⁶ Available via opt-in compat entrypoints (`refract/compat/react*`) with partial React API parity.
355
355
  ⁷ Preact compatibility is provided through `preact/compat`.
356
+ ⁸ Compat exports `Suspense`/`lazy`, but full suspension/fallback semantics are not implemented.
357
+ ⁹ `hydrateRoot` is exposed in compat, but currently performs client render rather than true SSR hydration.
358
+ ¹⁰ `memo` is supported; `PureComponent` is compat-oriented and does not guarantee full React shallow-compare behavior.
356
359
 
357
360
  ## License
358
361
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ipxjs/refract",
3
- "version": "0.10.0",
3
+ "version": "0.10.1",
4
4
  "description": "A minimal React-like virtual DOM library with an optional React compat layer",
5
5
  "type": "module",
6
6
  "main": "src/refract/index.ts",