Copy buttons do nothing in Firefox (clipboard API issue)
Platform: Firefox 127 (latest stable) on Windows 10
The Copy button in both the JSON Formatter and the Code Diff Viewer does nothing in Firefox. No error in the console, no clipboard feedback, nothing gets copied.
The exact same buttons work perfectly in Chrome. Steps to reproduce in Firefox:
1. Open Zetbit in Firefox
2. Go to JSON Formatter
3. Paste some JSON and format it
4. Click the Copy button
5. Nothing happens — clipboard is empty
Seems like a browser API compatibility issue, not a Zetbit-specific bug per se, but it does make the extension unusable in Firefox for anything involving copying output.
3 replies
Known Firefox quirk — the Clipboard API requires either a user gesture happening in the same frame OR an explicit permissions prompt. Extension popups have extra restrictions on top of that. The fix is to fall back to document.execCommand("copy") for Firefox, which is deprecated but still widely supported.
Can confirm this in Firefox 127 on my end too — JSON Formatter copy silently fails. Chrome is fine. Thanks for the detailed report Nina, having exact browser version + steps is really helpful for debugging this kind of API compatibility issue.
This is fundamentally a MV3 + Firefox compatibility gap. Firefox's Manifest V3 support is still catching up with Chrome's implementation. An execCommand fallback would be the safest cross-browser fix in the short term.
Sign in to join the discussion.
