โ– humdrum codex / soft
593 B raw
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
// Pin puppeteer's Chrome download + lookup OUT of ~/.cache, which cache cleaners
// (e.g. `mole clean`) wipe โ€” evicting Chrome and silently breaking PDF/edition
// generation. This data dir is not a cache, so cleaners leave it alone. Applies
// to both `npx puppeteer browsers install` and runtime executablePath lookup.
// Mirrored by PUPPETEER_CACHE_DIR in .env.local for the running Next server.
const { homedir } = require("node:os");
const { join } = require("node:path");

module.exports = {
  cacheDirectory: join(homedir(), ".local", "share", "personal-dashboard", "puppeteer"),
};