mirror of
https://github.com/loro-dev/loro.git
synced 2024-11-28 09:25:36 +00:00
chore: experimentally publish to jsr
This commit is contained in:
parent
8752c229f9
commit
df8bf029a6
4 changed files with 22 additions and 0 deletions
3
loro-js/deno/.vscode/settings.json
vendored
Normal file
3
loro-js/deno/.vscode/settings.json
vendored
Normal file
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"deno.enable": true
|
||||
}
|
5
loro-js/deno/deno.json
Normal file
5
loro-js/deno/deno.json
Normal file
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
"name": "@loro/loro",
|
||||
"version": "0.1.0",
|
||||
"exports": "./mod.ts"
|
||||
}
|
1
loro-js/deno/mod.ts
Normal file
1
loro-js/deno/mod.ts
Normal file
|
@ -0,0 +1 @@
|
|||
export * from "npm:loro-crdt@0.14.2";
|
13
loro-js/deno/test.ts
Normal file
13
loro-js/deno/test.ts
Normal file
|
@ -0,0 +1,13 @@
|
|||
import { Loro } from "./mod.ts";
|
||||
import { expect } from 'npm:expect'
|
||||
|
||||
Deno.test("test", () => {
|
||||
const doc = new Loro();
|
||||
const text = doc.getText("text");
|
||||
text.insert(0, "123")
|
||||
expect(text.toString()).toEqual("123");
|
||||
text.insert(0, "123")
|
||||
expect(text.toString()).toEqual("123123");
|
||||
const docB = Loro.fromSnapshot(doc.exportSnapshot());
|
||||
expect(docB.getText('text').toString()).toEqual("123123");
|
||||
})
|
Loading…
Reference in a new issue