{"id":14008591,"url":"https://github.com/nuchi/firefox-quantum-userchromejs","last_synced_at":"2026-01-16T12:55:05.221Z","repository":{"id":216050554,"uuid":"111857470","full_name":"nuchi/firefox-quantum-userchromejs","owner":"nuchi","description":"**Stops working with FF v72.** Firefox Quantum-compatible custom javascript in browser context — no extension, userChromeJS replacement.","archived":false,"fork":false,"pushed_at":"2019-12-23T06:32:00.000Z","size":10,"stargazers_count":129,"open_issues_count":1,"forks_count":16,"subscribers_count":13,"default_branch":"master","last_synced_at":"2024-08-11T11:03:39.785Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nuchi.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-11-23T23:27:03.000Z","updated_at":"2024-08-08T12:32:10.000Z","dependencies_parsed_at":null,"dependency_job_id":"70eaa2bd-a834-4cc4-8ccf-f8458aae2431","html_url":"https://github.com/nuchi/firefox-quantum-userchromejs","commit_stats":null,"previous_names":["nuchi/firefox-quantum-userchromejs"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuchi%2Ffirefox-quantum-userchromejs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuchi%2Ffirefox-quantum-userchromejs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuchi%2Ffirefox-quantum-userchromejs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nuchi%2Ffirefox-quantum-userchromejs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nuchi","download_url":"https://codeload.github.com/nuchi/firefox-quantum-userchromejs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":227410791,"owners_count":17774798,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-10T11:01:52.911Z","updated_at":"2026-01-16T12:55:05.213Z","avatar_url":"https://github.com/nuchi.png","language":"JavaScript","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"readme":"# Note: The trick contained in this repo stops working as of Firefox 72\n\n\u003e It's very possible that at some future time the Firefox team will remove some or all of the functionality that makes this possible, so enjoy it while you can.\n\nNow that the Firefox team has removed XBL from Firefox starting with version 72, this trick no longer works. It was a good run while it lasted!\n\nSee the Bugzilla tracking page [Disable MOZ_XBL in Firefox](https://bugzilla.mozilla.org/show_bug.cgi?id=1583314).\n\n# Firefox Quantum compatible userChrome.js\n\n## What does this do?\n\nExtensions that allow you to run arbitrary javascript in your browser context don't work anymore with Firefox 57 and later. This is a workaround which allows you to run arbitrary javascript in your browser context, as used to be enabled by the extension [userChromeJS](http://userchromejs.mozdev.org/).\n\nIt does not involve adding any extensions, and instead works only by adding (or changing) files in your Firefox user profile.\n\nAfter I made this I learned of something called `autoconfig.js` which apparently serves a similar purpose; I haven't investigated it very much.\n\n## Installation\n\nPlace the three `userChrome.*` files in a `/chrome` directory [inside your Firefox profile](https://support.mozilla.org/en-US/kb/profiles-where-firefox-stores-user-data). If you already have a `userChrome.css` file, you may instead add the contents of the file here anywhere in your existing file.\n\nReplace the contents of `userChrome.js` with whatever you wish; it will execute in the browser context whenever you open a new browser window. The existing contents of that script (in this repo) are a small change to the fullscreen behavior of Firefox under macOS: it restores the pre-Lion behavior (and hides the toolbar and tabs when in fullscreen mode).\n\nTo uninstall, remove the three files. If you have other content in the `userChrome.css` file you can remove just the part that you added during installation.\n\n## Why did I make it?\n\nI wanted to enable pre-Lion osx fullscreen mode, and couldn't find an easy way to do it in Firefox Quantum. It's possible with unpacking, altering, and repacking files in the `Firefox.app` package... but that's painful and might not survive updates. Then I came upon this method, realized this trick was far more general than just altering fullscreen mode, and factored it out so that the javascript part was easily modifiable by anyone.\n\n## How does it work?\n\nIt relies on the fact that post-57 Firefox still allows a custom `userChrome.css` file, and a Firefox-specific CSS hack which can bind javascript to arbitrary DOM elements. I picked (somewhat at random) a DOM element in the browser whose existing XBL binding didn't already have a `\u003cconstructor\u003e` tag, and added some JS there to load an external javascript file.\n\nIt's very possible that at some future time the Firefox team will remove some or all of the functionality that makes this possible, so enjoy it while you can.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuchi%2Ffirefox-quantum-userchromejs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnuchi%2Ffirefox-quantum-userchromejs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnuchi%2Ffirefox-quantum-userchromejs/lists"}