I learned a trick for developing GNOME extensions which saved me a bunch of time and hassle. Before I learned how to do this, I would have to log out and back in for every change I made to the extension - there's no built-in way to "reload" extensions in GNOME. With this technique, instead of logging out, I create a new, nested GNOME session and run the latest code from the extension I'm working on in there.
When you're ready to test, all you have to do is:
- package up your extension in a zip file as usual,
- install the new version,
- launch a nested session, and
- test your code.
Here's how that looks for my "Firefox PiP Always on Top" extension:
npm run build; # zip up the extension
gnome-extensions install --force ./firstname.lastname@example.org; # install
dbus-run-session gnome-shell --nested --wayland; # run a new session
--force flag when installing to make sure the old version is
I hope this quick tip helps you to build and share your GNOME extensions.