Goal 7 names the public surface; 39 exports sameAdf
This commit was merged in pull request #142.
This commit is contained in:
@@ -48,7 +48,9 @@ In priority order.
|
||||
6. **Failures are values.** Nothing throws, and `code` is a closed list — as much a contract as
|
||||
the emitted formats are.
|
||||
7. **Nothing in the way.** No runtime dependencies, no I/O, no configuration, no host API: ESM on
|
||||
any ES2022 engine, in a browser as readily as on a server, installed from public npm.
|
||||
any ES2022 engine, in a browser as readily as on a server, installed from public npm. The public
|
||||
surface is the conversions, their types, `isAdfDocument`, and what a consumer needs to check a
|
||||
guarantee this README makes; a helper is exported only when a persona cannot do without it.
|
||||
8. **Correct before fast.** Each format means what its own specification says — markdown as the
|
||||
CommonMark spec reads it, well-formed HTML as the HTML standard parses it — both in what this
|
||||
library reads and in what a conforming parser reads from what it writes. A call takes a whole
|
||||
|
||||
@@ -2,6 +2,10 @@
|
||||
|
||||
## 0.2.0
|
||||
|
||||
- **39 — Export `sameAdf(a, b)`, the equality README §The guarantees means.** Per Goal 7, it answers
|
||||
whether two documents are equal editor-normal (`docs/decisions.md` §Equality is editor-normal), and
|
||||
the guarantees' "equals `doc`" names it, since a deep-equal fails on a valid document holding an
|
||||
empty `attrs` or two adjacent text nodes with the same marks.
|
||||
- **35 — Read and write plain markdown as a flavour of the markdown grammar.** Per Goal 2 and
|
||||
`docs/decisions.md` §Plain markdown is a flavour of the grammar, README §Plain markdown's rows are
|
||||
read by `markdownToAdf`'s parser and written by `adfToMarkdown`'s writer, and the lift goes. The
|
||||
|
||||
Reference in New Issue
Block a user