Core library of "onion versioning".

Joeri Exelmans 4664762c6b Fix delta serialization 1 gadu atpakaļ
lib 4664762c6b Fix delta serialization 1 gadu atpakaļ
test 55e5ffbe86 the never-ending misery of config files 1 gadu atpakaļ
.gitignore d857d8c770 Fuck it. I'll add 'dist' to git repo 1 gadu atpakaļ
README.md aee2d05518 fixed! 1 gadu atpakaļ
index.ts 53a1e6acc5 add export 1 gadu atpakaļ
package.json f678903485 some more JS packaging bullshit 1 gadu atpakaļ
pnpm-lock.yaml 196218cdfb Create fork/package containing only library (no frontend) 1 gadu atpakaļ
todo.txt 2e0c8ff23e Merge branch 'master' into rewrite-core 1 gadu atpakaļ
tsconfig.json 55e5ffbe86 the never-ending misery of config files 1 gadu atpakaļ
tsconfig.lib.json 55e5ffbe86 the never-ending misery of config files 1 gadu atpakaļ

README.md

Onion Core Library

Defines:

  • Primitive delta types, their dependency and conflict relations.
  • (nestable) Transactions of deltas.
  • A "DeltaRegistry" that assigns content-based IDs to deltas, and reuses them.
  • A mutable "GraphState" class, for executing deltas.
  • A "Version" class, for graph embedding, branching and merging.

Currently depends on these NodeJS libraries: 'buffer', 'crypto' and 'stream'. This is only to compute hashes by means of synchronous function call (Web Crypto API only supports async). You can use polyfills to make this library work in the browser.

Typescript is a dependency of this package (not a 'devDependency') because otherwise the 'postinstall' script (which is automatically run by (p)npm after cloning this repo) fails. This may be a bug in (p)npm. I don't have time to investigate.