WordReference Translate is a Manifest V3 browser extension for Edge, Chrome, and Firefox that let the user access WordReference.com dictionaries conveniently from the extension popup window.
- Popup search UI with theme support, audio playback, source links, and interactive re-translation.
- In-page translation by context menu,
Alt+ selection, floating icon, or custom keyboard shortcut. - Auto-detect source language and inverted-language fallback when the direct lookup has no result.
- Local-only settings and UI state, including changelog visibility and optional page-integration permissions.
- Localized UI for
en,es,fr, andit. - Fully local popup autocomplete for
en,es,fr, andit.
- WXT
- TypeScript
- React for popup and options
- Plain TypeScript for background, parsing, messaging, and content-script logic
- Vitest for automated tests
npm install
cp .env.example .env
npm run devAll local-only metadata lives in .env. Keep .env untracked and commit only .env.example.
WXT_FIREFOX_ADDON_ID: required for Firefox MV3 development and buildsWXT_FIREFOX_STRICT_MIN_VERSION: optional Firefox minimum version, defaults to115.0WRT_EXTENSION_AUTHOR_NAME: shown in the options credits area when presentWRT_EXTENSION_AUTHOR_EMAIL: used for the contact section and Firefox manifestauthorWRT_EXTENSION_AUTHOR_WEBSITE: shown in credits when presentWRT_EXTENSION_REPO_URL: shown in the options contact section when presentWRT_CHANGELOG_ITEMS:||-separated changelog lines. If empty, the popup changelog and action badge stay hidden
npm run dev: Edge development buildnpm run dev:chrome: Chrome development buildnpm run dev:firefox: Firefox MV3 development buildnpm run build: Edge production buildnpm run build:chrome: Chrome production buildnpm run build:firefox: Firefox MV3 production buildnpm run zip: Edge zip packagenpm run zip:chrome: Chrome zip packagenpm run zip:firefox: Firefox MV3 zip packagenpm run build:autocomplete-datasets: regenerate the bundled local popup autocomplete datasets fromwordfreqnpm run lint: run ESLintnpm run lint:fix: apply safe ESLint fixesnpm run typecheck: run TypeScript checksnpm run test: run Vitest with coverage
- Edge:
.output/edge-mv3 - Chrome:
.output/chrome-mv3 - Firefox:
.output/firefox-mv3
- Run
npm run build. - Open
edge://extensions. - Enable Developer mode.
- Choose Load unpacked.
- Select
.output/edge-mv3.
- Run
npm run build:chrome. - Open
chrome://extensions. - Enable Developer mode.
- Choose Load unpacked.
- Select
.output/chrome-mv3.
- Make sure
.envcontainsWXT_FIREFOX_ADDON_ID. - Run
npm run build:firefox. - Open
about:debugging#/runtime/this-firefox. - Choose Load Temporary Add-on.
- Select
manifest.jsoninside.output/firefox-mv3.
src/entrypoints: WXT entrypoints for popup, options, background, and content scriptssrc/core: translation fetch flow, auto-detect strategy, and HTML parsingsrc/shared: settings, permissions, build metadata, messaging, and HTML normalization helperssrc/ui: popup and options UI sections plus shared stylespublic/_locales: localization filestests: parser, translation, storage, changelog, and helper tests
Required permissions:
storagecontextMenusscriptinghttps://www.wordreference.com/*
Optional host permissions:
http://*/*https://*/*
Runtime network access is limited to:
https://www.wordreference.com/*for lookups and media- explicit user-clicked links opened from extension UI
The extension does not include:
- login or authentication
- payments or gated features
- remote database calls
- remotely executed code
Popup word autocomplete uses bundled static datasets generated offline from wordfreq. See THIRD_PARTY_NOTICES.md before regenerating or redistributing those files.
See CONTRIBUTING.md for setup, architecture notes, and PR expectations.
MIT