Skip to main content
This release is 1 version behind 0.1.1 — the latest version of @tkancharla/tandem. Jump to latest

A sync engine and database for building collaborative apps

It is unknown whether this package works with Cloudflare Workers, Node.js, Deno, Bun, Browsers
It is unknown whether this package works with Cloudflare Workers
It is unknown whether this package works with Node.js
It is unknown whether this package works with Deno
It is unknown whether this package works with Bun
It is unknown whether this package works with Browsers
JSR Score
52%
Published
2 days ago (0.1.0)
class LocalTransaction

Constructors

new
LocalTransaction(
tupleDbTx: TupleRootTransactionApi,
)

Type Parameters

Schema extends AnySchema

Properties

private
readonly
ops: MutationOp[]

Methods

cancel(): void
commit(): void
get<Collection extends CollectionName<Schema>>(
collection: Collection,
id: string,
): Readonly<Schema[Collection]> | undefined
list<Collection extends CollectionName<Schema>>(collection: Collection): Readonly<Schema[Collection]>[]
remove<Collection extends CollectionName<Schema>>(
collection: Collection,
id: string,
): LocalTransaction<Schema>
set<Collection extends CollectionName<Schema>>(
collection: Collection,
record: Schema[Collection],
): LocalTransaction<Schema>

Add Package

deno add jsr:@tkancharla/tandem

Import symbol

import { LocalTransaction } from "@tkancharla/tandem";

---- OR ----

Import directly with a jsr specifier

import { LocalTransaction } from "jsr:@tkancharla/tandem";

Add Package

npx jsr add @tkancharla/tandem

Import symbol

import { LocalTransaction } from "@tkancharla/tandem";

Add Package

yarn dlx jsr add @tkancharla/tandem

Import symbol

import { LocalTransaction } from "@tkancharla/tandem";

Add Package

pnpm dlx jsr add @tkancharla/tandem

Import symbol

import { LocalTransaction } from "@tkancharla/tandem";

Add Package

bunx jsr add @tkancharla/tandem

Import symbol

import { LocalTransaction } from "@tkancharla/tandem";