automerge/rust/automerge-wasm/deno-tests/deno.ts
Alex Good 5763210b07
wasm: Allow a choice of text representations
The wasm codebase assumed that clients want to represent text as a
string of characters. This is faster, but in order to enable backwards
compatibility we add a `TextRepresentation` argument to
`automerge_wasm::Automerge::new` to allow clients to choose between a
`string` or `Array<any>` representation. The `automerge_wasm::Observer`
will consult this setting to determine what kind of diffs to generate.
2023-01-10 12:52:19 +00:00

8 lines
212 B
TypeScript

// @deno-types="../index.d.ts"
import { create } from '../deno/automerge_wasm.js'
Deno.test("It should create, clone and free", () => {
const doc1 = create(false)
const doc2 = doc1.clone()
doc2.free()
});