Skip to content

Repository files navigation

Grammar Checker Extension

Overview

This Chrome extension provides real‑time grammar checking for Thai, English, and Japanese without using AI. It includes a popup UI for quick toggles and an options page for detailed configuration.

Project Structure

grammar-checker-extension/
├─ src/
│  ├─ background.js      # Service worker
│  ├─ content.js         # Content script
│  ├─ popup.html
│  ├─ popup.js
│  ├─ options.html
│  └─ options.js
├─ dist/                  # Build output (generated by Vite)
├─ icons/                 # Extension icons
├─ manifest.json
├─ package.json           # Build scripts
└─ README.md

Build & Development

Prerequisites

  • Node.js (>=18)
  • npm (comes with Node)

Install dependencies

npm install

Development server

Run a Vite dev server that watches the src folder and outputs to dist:

npm run dev

Open chrome://extensions/, enable Developer mode, and click Load unpacked → select the dist folder generated by Vite.

Build for production

npm run build

The dist folder will contain the compiled extension ready for publishing.

Usage

  1. Click the extension icon to open the popup.
  2. Toggle the extension on/off, choose correction mode (inline or clipboard), and select performance mode.
  3. Right‑click any text field → Check Grammar to run a manual check.
  4. Open the Options page (via the gear icon in the popup) to configure:
    • Enable/disable the extension globally
    • Select languages to check (Thai, English, Japanese)
    • Choose correction mode
    • Adjust debounce delay for live checking

Settings are persisted with chrome.storage.sync.

Permissions

The extension requests the following permissions:

  • storage – Store user settings locally
  • activeTab – Check grammar in the current active tab
  • offscreen – Service worker operations (Chrome Manifest V3)
  • clipboardWrite – Write corrected text to the clipboard
  • contextMenus – Add the Check Grammar menu item
  • host_permissions: <all_urls> – Work on any website (Gmail, Google Docs, etc.)

Privacy Note: All permissions are used for local processing only. See PRIVACY.md for details.

Privacy & Security

🔒 Your data never leaves your device (unless you explicitly enable optional LanguageTool integration)

  • ✅ All grammar checking is performed locally on your device
  • No tracking, no analytics, no telemetry
  • No external servers - we don't have any!
  • ✅ Settings stored locally using Chrome storage API
  • ✅ Optional LanguageTool API integration (disabled by default, requires your own API key)

For full details, see our Privacy Policy.

Contributing

  1. Fork the repository.
  2. Create a feature branch.
  3. Make changes in the src folder.
  4. Run npm run dev to test locally.
  5. Submit a pull request.

License

MIT © 2025 Naphatsadon4596

About

No description, website, or topics provided.

Resources

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages