A simple and efficient browser extension that automatically redirects Google Translate URLs (translate.goog) back to their original source websites.
- Automatic Redirection: Instantly detects and redirects Google Translate pages to the original URL.
- Privacy Focused: Only runs on
*.translate.googdomains. - Simple Control: Toggle the extension on/off directly from the popup.
- Node.js = v22.14
- pnpm >= v10.13.1
- Clone this repository
- Install dependencies:
pnpm install
- Build the extension:
pnpm build
- Load the extension in your browser:
- Chrome: Go to
chrome://extensions/, enable "Developer mode", and click "Load unpacked" -> Selectbuild/chrome-mv3-prod(or similar depending on build output) - Firefox: Go to
about:debugging, click "This Firefox", and click "Load Temporary Add-on" -> Selectbuild/firefox-mv2-prod
- Chrome: Go to
- Click the extension icon to see the status.
- Use the toggle button to Enable or Disable the redirection.
- When enabled, navigating to any
*.translate.googURL will automatically redirect you to the original site.
pnpm dev: Start development serverpnpm build: Build extension for productionpnpm test: Run the test suite (Vitest)pnpm package: Create a package for distribution
The project includes a comprehensive test suite using Vitest and React Testing Library.
- Unit Tests: Located in
src/utils/*.test.ts, covering URL redirection logic and settings management. - Component Tests: Located in
src/*.test.tsx, covering the popup UI and user interactions.
To run the tests:
pnpm testMIT