Skip to content

jinkijack/CookieManager

Repository files navigation

Cookie Manager icon

Cookie Manager

Bulk view, copy, and set browser cookies from a standard cookie header string.
Manifest V3 · Chrome / Edge / Firefox · React + TypeScript


A developer-focused browser extension: open the popup and see the active tab's cookies as a standard name=value; name2=value2 header string, copy them with one click, or paste a header string to set many cookies at once — optionally clearing the existing ones first. Inspired by the classic cookiedough, rebuilt from scratch on a modern stack.

Features

  • 🍪 View the active tab's cookies in Cookie header format
  • 📋 Copy them to the clipboard with one click
  • ✍️ Bulk-set cookies by pasting a header string (foo=bar; baz=qux)
  • 🧹 Clear-first toggle to wipe existing cookies before setting new ones
  • 🌗 Light/dark theme with system detection and persisted preference
  • 🌐 Cross-browser: Chrome, Edge, and other Chromium browsers, plus Firefox (Manifest V3, browser.* fallback, runtime host-permission grant flow)

Installation

From source

npm install
npm run build
  • Chrome / Edge: open chrome://extensions, enable Developer mode, click Load unpacked, and select the dist/ folder.
  • Firefox: open about:debugging#/runtime/this-firefox, click Load Temporary Add-on, and select dist/manifest.json.

On first use, click Grant access in the popup. Host access is intentionally not required at install time — the extension declares optional_host_permissions and asks for it at runtime, so you stay in control of when it can touch cookies.

Development

npm run dev        # Vite dev server for the popup UI
npm test           # Vitest: unit, property-based (fast-check), and integration
npm run lint       # oxlint
npm run typecheck  # tsc, strict mode
npm run icons      # regenerate PNG icons from assets/icon.svg

Architecture

Strict layering keeps the cookie logic fully testable without a browser:

src/
  utilities/   pure functions: cookie header parser/formatter, URL scheme check
  services/    browser I/O behind mockable interfaces (cookies, tabs,
               clipboard, storage) over a chrome.*/browser.* abstraction
  hooks/       reusable interaction state (async status, theme)
  components/  React popup UI

The parser/formatter pair carries a round-trip guarantee verified with property-based tests (fast-check, 100+ runs per property).

Store packaging

npm run package          # releases/cookie-manager-v<version>.zip  (dist build)
npm run package:source   # releases/cookie-manager-v<version>-source.zip (AMO review)

Build instructions for reviewers

The extension is built with TypeScript + Vite (bundled and minified), so the store package is generated from this source as follows:

  • Operating system: any Linux/macOS/Windows with Node.js
  • Node.js: 20.x (built with v20.20.2)
  • npm: 10.x (built with 10.8.2)
npm ci        # install exact dependencies from package-lock.json
npm run build # tsc + vite build → output in dist/

The contents of dist/ are exactly what is packaged and uploaded to the store (npm run package zips that folder). No other processing is applied.

Privacy

All data stays in your browser — no network requests, no analytics, no tracking. See PRIVACY.md.

License

MIT

About

A developer-focused browser extension: open the popup and see the active tab's cookies as a standard name=value; name2=value2 header string, copy them with one click, or paste a header string to set many cookies at once — optionally clearing the existing ones first. Inspired by the classic cookiedough, rebuilt from scratch on a modern stack.

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages