import { Earthstar } from "https://deno.land/x/earthstar_replica_server@4.0.0-beta.1/deps.ts";
const { MultiformatReplica } = Earthstar;
Type Parameters
optional
F = DefaultFormatParameters
doc: FormatDocType<F>
attachment: Uint8Array | ReadableStream<Uint8Array>
Returns
Promise<true | false | ValidationError>
true
(indicating it was upsert), false
(indicating this attachment is already in storage), or a ValidationError
(indicating something went wrong.)