Feed database type for orbit-db.
$ pnpm add @orbitdb/feed-db
Feed database for those feeling nostalgic for orbit-db v.0.x. But honestly, you're probably better off with a KeyValue or a Set.
import { createOrbitDB, useDatabaseType } from "@orbitdb/core";
import { Feed } from "@orbitdb/feed-db";
// Register database type. IMPORTANT - must call before creating orbit instance !
useDatabaseType(Feed);
const orbit = await createOrbitDB()
const db = await orbit.open({ type: "feed" });
await db.add({ a: 1, b: "c" });
const all = await db.all(); // [{ value: { a: 1, b: "c" }, hash: "..." }]
await db.add({ a: 1, b: "c" });
await db.all();
// [{ value: { a: 1, b: "c" }, hash: "..." }, { value: { a: 1, b: "c" }, hash: "..." }]