@madojs/mado 0.13.0 → 0.13.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.13.1 - 2026-07-11
4
+
5
+ ### Fixed
6
+
7
+ - Static capture now waits for asynchronous module bootstrap before reading
8
+ the runtime handshake. This removes a top-level-await race that surfaced on
9
+ slower Windows CI runners as `window.__MADO_STATIC__ was not installed`.
10
+
3
11
  ## 0.13.0 - 2026-07-11
4
12
 
5
13
  The final planned pre-v1 breaking release hardens ownership and freezes the
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@madojs/mado",
3
- "version": "0.13.0",
3
+ "version": "0.13.1",
4
4
  "description": "A calm native-first web framework for sites and apps. Web Components, signals, routing, data, forms and browser-rendered static snapshots. Zero runtime dependencies.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -212,6 +212,15 @@ async function captureRoute(browser, record, options) {
212
212
 
213
213
  async function waitForMadoStability(page, record, timeout) {
214
214
  try {
215
+ // DOMContentLoaded does not guarantee that an async module graph has
216
+ // finished evaluating. Apps may legitimately use top-level await during
217
+ // bootstrap (the modular starter restores auth this way), so wait for the
218
+ // runtime handshake instead of reading it once and racing slow runners.
219
+ await page.waitForFunction(
220
+ () => window.__MADO_STATIC__ !== undefined,
221
+ undefined,
222
+ { timeout },
223
+ );
215
224
  await withTimeout(
216
225
  page.evaluate(async () => {
217
226
  const runtime = window.__MADO_STATIC__;