refactor: le paquet s'appelle polyfill, « SDK » désigne celui de NextGraph

Le nom @ng-eventually/sdk entrait en collision avec le SDK de NextGraph, dont
ce paquet est justement un polyfill. Impossible d'écrire « le SDK » sans lever
l'ambiguïté à chaque phrase — et le contrat publié, lu par une application,
était le pire endroit pour laisser traîner ça.

packages/sdk → packages/polyfill, @ng-eventually/sdk → @ng-eventually/polyfill,
contract_sdk-surface → contract_polyfill-surface, e2e/sdk-entry.ts →
e2e/polyfill-entry.ts, docs/sdk-reference.md → docs/polyfill-reference.md.

Les occurrences de « SDK » qui désignent celui de NextGraph restent intactes,
y compris les chemins dans nextgraph-rs (sdk/js/orm, sdk/js/web). Le tri s'est
fait occurrence par occurrence, pas par substitution.

Le contrat énonce désormais son identité en une phrase : « This package is a
polyfill of NextGraph's SDK. »
This commit is contained in:
Sylvain Duchesne
2026-08-10 17:14:25 +02:00
parent 49b046268e
commit 737729c9ce
88 changed files with 122 additions and 106 deletions
+3 -3
View File
@@ -5,7 +5,7 @@ shared wallet. This is a design decision, grounded entirely in the query
capability documented in
[`nextgraph-current-state.md`](./nextgraph-current-state.md) § *The query
capability*. The consumer application never sees any of this: it asks
`@ng-eventually/sdk` for its lists by need and trusts the answer — the whole
`@ng-eventually/polyfill` for its lists by need and trusts the answer — the whole
read mechanism lives here, in the polyfill.
> The rule in one line: read each by-need doc with its own anchored
@@ -111,7 +111,7 @@ Keep the reactive ORM strictly to already-opened single stores; it is a change
## The boundary with the consumer application
The consumer application asks the SDK for its lists by need and trusts the returned
The consumer application asks the polyfill for its lists by need and trusts the returned
set. It never constructs a NURI, never picks the union-vs-anchor mode, never touches
the ORM. The domain-shaped list helpers (e.g. "my meeting points", "events") live in
the consumer application, not the lib; the lib exposes the generic by-need read.
@@ -172,7 +172,7 @@ and never iterates the other named graphs. (A repo absent from `self.repos` thro
`RepoNotFound` and is skipped per-doc, see the VERIFIED note above — the read cannot
sync an unknown repo.)
> **Re-confirmed by the standing e2e harness (`packages/sdk/e2e/`, broker
> **Re-confirmed by the standing e2e harness (`packages/polyfill/e2e/`, broker
> `@ng-org/web 0.1.2-alpha.13`).** The `docRoundTrip` check measures all three shapes
> anchored to a doc D: (a) a no-GRAPH default-graph write round-trips; (b) an explicit
> `INSERT DATA { GRAPH <D> {…} }` — a **constant** plain NURI — **also** round-trips