1 2 3 4 5 6 7
// Monkey patch ServiceWorker.postMessage so that it will actually post a notification in Ferdium: function newPostMessage(options) { window.ferdium.displayNotification(options.title, options); } ServiceWorker.prototype.postMessage = newPostMessage;