cache

cache controls whether Chromium-based browsers reuse a dev user data directory between addfox dev runs. It affects only dev mode and only Chromium-family browsers.

Type and default

  • Type: boolean | undefined
  • Default: true
  • CLI precedence:
    • -c/--cache forces cache on for current run
    • --no-cache forces cache off for current run
    • If both are provided, the last flag wins

Role

  • When true (or CLI --cache is used):
    • Dev mode caches a Chromium user data dir under the internal cache path, so:
      • extension install state
      • extension settings
      • login sessions and cookies are kept between addfox dev runs.
  • When false:
    • Each addfox dev run uses a fresh temporary profile for Chromium-based browsers.
  • Does not affect Firefox; Firefox profile handling is delegated to web-ext.

Examples

Enable caching via config

export default defineConfig({
  cache: true,
});

One-off caching via CLI

pnpm
npm
yarn
bun
pnpm dev -- --cache
# or
pnpm dev -- -c

One-off disable via CLI

pnpm
npm
yarn
bun
pnpm dev -- --no-cache

CLI flags override cache in config for that run.