Guide
Browser extension changelog on update
Chrome, Edge and Firefox update extensions quietly in the background, so most people never learn that you fixed the bug they reported or added the option they asked for. Few people go back to the store listing after they install, so a note about the update there rarely reaches them.
A common fix is to open a short "what's new" page right after an update. You can do that with a hosted ShipLog changelog, so you write each release once and every update links people to it.
Open the page after an update
Chrome, Edge and Firefox fire the runtime.onInstalled
event when someone installs your extension or the browser updates it, and the event tells you the reason and the previous version. Add this to your background script, which is a service worker in Chrome and Edge:
chrome.runtime.onInstalled.addListener((details) => {
if (details.reason !== "update") return;
const version = chrome.runtime.getManifest().version;
if (details.previousVersion === version) return;
chrome.tabs.create({
url: "https://YOUR-CHANGELOG-URL?utm_source=extension&utm_medium=update"
});
});
Firefox accepts the same code through the chrome
namespace, or you can call browser.runtime
and browser.tabs
instead. Opening a new tab this way doesn't need the tabs
permission.
Keep it polite
Opening a tab on every patch release annoys people. Compare the major and minor parts of the two version numbers and only open the page when one of them changes, or store a "don't show again" choice in
chrome.storage
and respect it. For small fixes you can set a badge on the toolbar icon with
chrome.action.setBadgeText
and show the latest entry inside your popup instead.
Show the latest entry inside the popup
If you'd rather not open a tab at all, fetch the RSS feed of your public changelog from the popup and render the newest item's title, date and summary. The feed allows requests from any origin, so you don't need to add its domain to host_permissions. Cache the result so the popup opens fast.
Steps
- Create a free ShipLog project and publish your first changelog entry. The free plan includes one project with 10 changelog entries, and you can import your existing GitHub releases.
- Copy your public changelog URL and paste it into the listener above.
- Raise the version in your manifest, then reload the unpacked extension from the extensions page and check that the page opens. The listener skips a reload that keeps the same version.
- Link the same changelog from your store listing and your website, so everyone reads the same words.
Building a desktop or command-line app too? Read show release notes in your app's update dialog.