Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ are expected and listed without apology.

## Unreleased

- The site, the articles, the principles, the vision, and the recipes are
written in plain sentences. The claims, the numbers, the code samples,
and the decision records are unchanged.
- `docs/recipes/accounts.md`: a sign-out, a switch of accounts, and what
the disk keeps. Where the account lives, in the image's path or its
`version`; the order of a sign-out, end the environment, remove the
Expand Down
80 changes: 42 additions & 38 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,49 +3,53 @@
What to read when.

- **What is this, and why is it shaped this way?**
[vision.md](vision.md) — the argument and the five rules.
[vision.md](vision.md) is the argument and the five rules.
- **Why GraphQL at all, and where do my view models go?**
[why-graphql.md](why-graphql.md) — GraphQL for iOS and Android engineers
who have built on REST: what it is, what it changes, what it costs.
[why-graphql.md](why-graphql.md) is for iOS and Android engineers who
have built on REST: what it is, what it changes, and what it costs.
- **Why is this decision the way it is?**
[principles/](principles/) — one file per constraint: the failure mode it
avoids, the idea, the consequences, the rejected alternatives, and how it
is spelled in code today.
[principles/](principles/) has one file per constraint: the failure it
avoids, the idea, the consequences, the rejected alternatives, and how
it is spelled in code today.
- **Why this and not the alternative?**
[decisions/](decisions/) — one file per choice: context, decision,
evidence, what was not chosen, and what would reopen it.
[decisions/](decisions/) has one file per choice: the context, the
decision, the evidence, what was not chosen, and what would reopen it.
- **How does this compare with the other native clients?**
[comparison.md](comparison.md) — approaches, numbers, pros and cons.
[comparison.md](comparison.md) sets out the approaches, the numbers, and
the pros and cons.
- **Why this shape, argued at length?**
[articles/](articles/) — one essay per choice that shapes the library:
Relay without the read side, what Meta built, why it is fast, the first
frame, two runtimes, the compiler, how a fast store stays honest, the
twelve words, Baton beside fate, the small lies a client tells, and how
it is built.
[articles/](articles/) holds one essay per choice that shapes the
library: Relay without the read side, what Meta built, why it is fast,
the first frame, two runtimes and the compiler. Further essays cover how
a fast store stays honest, the twelve words, Baton beside fate, the small
lies a client tells, and how it is built.
- **What does this word mean?**
[terminology.md](terminology.md) — the vocabulary contract, updated in the
same change as the code. Concepts marked *(planned)* do not exist yet.
[terminology.md](terminology.md) is the vocabulary contract, updated in
the same change as the code. Concepts marked *(planned)* do not exist
yet.
- **Where is it, in each runtime?**
[runtimes.md](runtimes.md) — the map of both trees, a file per concept,
[runtimes.md](runtimes.md) is the map of both trees, a file per concept,
checked by the boundary script.
- **How do I…** — [recipes/](recipes/), one page per composition of what
ships: [integrating Baton with a coding
agent](recipes/agents.md), the page an agent reads first, [the exchange](recipes/exchange.md), a challenge, a retry and a
deadline over the transport's one verb, [`batonc`](recipes/batonc.md),
the compiler's command line for a build outside SwiftPM,
[Bazel](recipes/bazel.md), the compiler as a toolchain and one rule over
its command, [Gradle](recipes/gradle.md), the Kotlin runtime from Maven
Central and the compiler as a task, and
[previews and tests](recipes/testing.md), a store without a server,
[UIKit and AppKit](recipes/uikit.md), a handle held by a controller,
[views and view models](recipes/views.md), a Kotlin handle without a
composition, [outside views](recipes/outside-views.md), a fetch, a read
and a write from code that is not a view, [accounts](recipes/accounts.md),
a sign-out, a switch and what the disk keeps, and
[porting from Relay](recipes/porting-from-relay.md), Relay's words beside
Baton's, and [derived state outside views](recipes/derived-state.md), a
model over `Observations` or `snapshotFlow`, and [discover once, refresh through
`nodes(ids:)`](recipes/discover-once.md), the pattern for external keys.
The rest arrive with the releases that make them true.
- **What did a decision open up?** — [openings/](openings/), written as the
project ships. None yet.
- **How do I...** [recipes/](recipes/) has one page per composition of what
ships. [integrating Baton with a coding agent](recipes/agents.md) is the
page an agent reads first. [the exchange](recipes/exchange.md) is a
challenge, a retry and a deadline over the transport's one verb.
[`batonc`](recipes/batonc.md) is the compiler's command line for a build
outside SwiftPM. [Bazel](recipes/bazel.md) is the compiler as a toolchain
and one rule over its command. [Gradle](recipes/gradle.md) is the Kotlin
runtime from Maven Central and the compiler as a task.
[previews and tests](recipes/testing.md) is a store without a server.
[UIKit and AppKit](recipes/uikit.md) is a handle held by a controller.
[views and view models](recipes/views.md) is a Kotlin handle without a
composition. [outside views](recipes/outside-views.md) is a fetch, a read
and a write from code that is not a view.
[accounts](recipes/accounts.md) is a sign-out, a switch and what the disk
keeps. [porting from Relay](recipes/porting-from-relay.md) sets Relay's
words beside Baton's.
[derived state outside views](recipes/derived-state.md) is a model over
`Observations` or `snapshotFlow`.
[discover once, refresh through `nodes(ids:)`](recipes/discover-once.md)
is the pattern for external keys. The rest arrive with the releases that
make them true.
- **What did a decision open up?** [openings/](openings/) is written as the
project ships. There are none yet.
48 changes: 25 additions & 23 deletions docs/articles/README.md
Original file line number Diff line number Diff line change
@@ -1,44 +1,46 @@
# Articles

The design argued at length. Each page takes one choice that shapes the
library, says what the alternatives were and what they cost, and puts the
evidence beside it: the numbers from [BENCHMARKS.md](../../BENCHMARKS.md), the
decision records under [decisions/](../decisions/), and the public record of
the clients Baton is compared with. The short forms are the
[vision](../vision.md) and the [principles](../principles/); these are the
These pages argue the design at length. Each page takes one choice that
shapes the library and says what the alternatives were, what they cost, and
where the evidence sits.

The numbers are in [BENCHMARKS.md](../../BENCHMARKS.md), the decision
records are under [decisions/](../decisions/), and the public record of the
clients Baton is compared with is here too. The short forms are the
[vision](../vision.md) and the [principles](../principles/). These are the
long ones, in reading order.

- [Relay without the read side](relay-without-the-read-side.md): why Baton
keeps Relay's compiler and the write side of its store and deletes the read
side, because Observation and snapshot state already answer the question
keeps Relay's compiler and the write side of its store, and deletes the
read side. Observation and snapshot state already answer the question
Relay's runtime was built to answer.
- [What Meta built, and what you can download](what-meta-built.md): the public
record of Meta's in-house native client, where Baton makes the same choices,
and where it goes further.
- [What Meta built, and what you can download](what-meta-built.md): the
public record of Meta's in-house native client, where Baton makes the same
choices, and where it goes further.
- [Materialization is the bill](materialization-is-the-bill.md): why Baton is
faster than Apollo iOS and Apollo Kotlin on the same data, itemized on a Mac
and on a phone, with the caveats.
- [The first frame has the data](the-first-frame.md): synchronous reads on the
main actor, the image on disk, what a phone measured, and the fix the trace
asked for.
faster than Apollo iOS and Apollo Kotlin on the same data, with the bill
itemized on a Mac and on a phone, and the caveats.
- [The first frame has the data](the-first-frame.md): synchronous reads on
the main actor, the image on disk, what a phone measured, and the fix the
trace asked for.
- [Two runtimes, no bridge](two-runtimes-no-bridge.md): why the runtime is
written twice instead of shared through a Rust core, and what holds the two
to one behaviour.
written twice, instead of shared through a Rust core, and what holds the
two to one behaviour.
- [A compiler, not a configuration](a-compiler-not-a-configuration.md): what
is settled at build time, why the runtime has no parser and no policy
object, and why that matters more now that agents write screens.
- [How a fast store stays honest](how-a-fast-store-stays-honest.md): the
oracle, the fixtures, Relay's own tests measured against, and the benches
that keep every claim checkable.
- [Twelve words, and why the list is closed](twelve-words.md): the closed
vocabulary, what it refused and why, and how it looks beside a client
that dropped GraphQL and the clients that chose configuration.
vocabulary, what it refused and why, and how it looks beside a client that
dropped GraphQL and beside the clients that chose configuration.
- [Baton beside fate](baton-beside-fate.md): a client that took Relay's
insights and removed GraphQL, beside one that kept the compiler; where
they agree, where they part, three mechanisms watched, and a proof against
insights and removed GraphQL, beside one that kept the compiler: where
they agree, where they part, three mechanisms to watch, and a proof against
fate's own server.
- [The small lies a client tells](the-small-lies.md): six ways GraphQL
clients lie about data, and the types, directives and events that keep
clients lie about data, and the types, directives, and events that keep
Baton from each.
- [Settled stays settled](settled-stays-settled.md): how Baton is built,
habit by habit, each with the mechanism that fails when the habit is
Expand Down
Loading
Loading