79754467

Date: 2025-09-03 10:40:16
Score: 0.5
Natty:
Report link

I had a similar problem when I needed a lightweight, file-based database in Node.js. I tried lowdb (works, but very limited) and nedb (no longer maintained).

What worked well for me was DarkDB

. It stores data in plain files (JSON, YAML, TOML, or binary) and still provides things like:

simple set/get/delete/has operations

TTL support (keys expire automatically)

transactions for multi-step updates

basic query engine with filters

Example:

const DarkDB = require("darkdb");
const db = new DarkDB({ name: "mydb", format: "json" });
await db.set("user.name", "Alice");
console.log(await db.get("user.name")); // Alice
await db.set("session.token", "abc123", { ttlMs: 5000 });

It’s not a replacement for MongoDB or SQLite, but if you just need something embedded, file-based and fast, this library is a good option.

https://www.npmjs.com/package/darkdb

Reasons:
  • Blacklisted phrase (0.5): I need
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Mr Dark