chore: les dix injections de useShape passent par le faux partage

Dix sites, pas les deux que le suivi annoncait : `(() => {}) as unknown as
UseShapeLike` survivait la ou le type etait encore `any` et ou le cast ne
disait donc rien. Ils prennent le faux partage, sans cast.
This commit is contained in:
Sylvain Duchesne
2026-09-24 19:00:25 +02:00
parent c5de1cea35
commit d4b392a119
6 changed files with 16 additions and 10 deletions
@@ -29,6 +29,7 @@
*/
import { test, expect, describe, mock, beforeEach } from "bun:test";
import { makeUseShapeHook } from "./use-shape-fake";
import { configure, storeRegistry, docs } from "../src/index";
import { configureStoreRegistry } from "../src/shared-wallet/bootstrap";
import { sparqlUpdate } from "../src/surface/docs";
@@ -84,7 +85,7 @@ function bootPage(quads: Quad[], lostAt: (query: string) => boolean): void {
return wallet.sparql_query(...a);
}),
};
configure({ ng: ng as unknown as NgLike, useShape: (() => {}) as unknown as UseShapeLike });
configure({ ng: ng as unknown as NgLike, useShape: makeUseShapeHook().hook });
configureStoreRegistry({ getSession: async () => SESSION, normalizeId: (id) => id.trim() });
}