Chrome Extension Debugging Lessons — Domain Whitelist, Duplicate Listeners, Closure Pitfalls

When maintaining a Chrome extension, “this should definitely work, why doesn’t it?” comes up more often than expected. I made four consecutive mistakes in a short period, each with a different root cause. Writing them down. 1. A return in the dispatch block silently kills generic detection Content scripts typically end with a pattern like this: if (isSomeSpecificPage()) { doSomethingSpecific(); return; // ← exits here } // Generic DOM detection (MutationObserver, etc.) const observer = new MutationObserver(() => { ... }); observer.observe(document.body, { childList: true, subtree: true }); After adding a feature for a specific domain with an early return, the generic DOM detection never ran in a popup window on that domain. ...

2026-03-09 · 5 min read · Seunghan
Chrome Extension Oacx Iframe Korean Ime Fix

Chrome Extension iframe OACX Auto-Fill Not Working — Timing and Korean IME Issues

I built a Chrome extension that auto-fills the OACX (simplified authentication) form on Korean government sites. It worked on most sites, but got feedback saying “the name field isn’t being filled” on a specific major site. Symptoms Extension auto-fills name, birthdate, and phone number when the simplified auth popup opens Works correctly on most government sites (Gov24, National Health Insurance, etc.) Only on a specific site, the name field was empty – birthdate and phone number also weren’t filled Investigation: Checking Actual DOM Structure with Playwright Opened the page reported by the user directly using Playwright MCP. ...

2026-01-23 · 5 min read · Seunghan
Privacy Policy Terms Disclaimer Contact