const diff: <T>(a: T, b: T) => Update<T>
Diff values A and B
Ensures patch(A, diff(A, B)) equals B.
patch(A, diff(A, B))
B
packages / state / src / patch.ts