It’s 2009 and no browser vendor supports notifications for Webapps. The revolution begins today.
Let me first explain in Simple English: (1) Install Yip, (2) Go to Meebo.com and (3) When you receive an IM, you’ll see a notification on your screen like the one in the screenshot below. Works for Filttr.com and a whole host of other sites too.
Now for the explanation that geeks prefer – Yip is a Firefox extension that ports the Fluid and Prism notification APIs over to Firefox so you can receive Growl notifications from web applications. (Update: with Yip 0.2, if you’re on Windows, you can get Snarl or Growl for Windows or plain old Firefox notifications and if you use Linux, you can get libnotify/notify-OSD notifications. Read more about this here).
The great thing about Yip is that we don’t have to be stuck in a chicken-and-egg situation. Many websites have already implemented notifications (despite the fact that no major browser has added support for it!). Some support Fluid, some support Prism and some do both. So, you can immediately start using Yip.
If you log into Meebo and you have Yip installed, the next time your friends sends you an IM, you should see a notification (obviously, Meebo should not be your focused window/tab at that point).
Apologies to my Chinese readers. I merely take screenshots and post them without reflecting on their contents.
Another cool website is Filttr which is a Twitter app that supports notifications for replies and direct messages.
A number of other Webapps also support notifications. And there are a whole slew of Greasemonkey userscripts to enable notifications for Facebook, Gmail, FriendFeed, Github, etc.
Yet another standard?
As pointed out earlier — NO, the goal of Yip is not to create a standard for notifications but to support all the existing kinds of notifications. Currently, Yip only supports Fluid and Prism which cover the large majority (100%?) of currently implemented notifications. When Gears/Chrome starts supporting notifications (which might never happen because I don’t see anyone working on the proposal), Google will no doubt add notifications to all its web apps. Then, I’ll add support for the Gears Notification API to Yip too. If you know any other API, let me know in the comments and I’ll support it.
The API
Fluid
If you want to support notifications on your website, Fluid’s API is great. The function takes a single jQuery-style argument:
window.fluid.showGrowlNotification({
title: "title",
description: "description",
onclick: callbackFunc,
icon: URL string
});
All arguments are optional. Note that Fluid/Growl also supports the priority, sticky and identifier properties which are not yet supported by Yip.
Prism
Yip also supports the Prism API. Unfortunately, this API does not support even an onclick callback so I recommend that you use window.fluid instead. But since both Prism and Yip run on XULRunner, I’ll probably add a patch to Prism soon. Here, all arguments must be specified:
window.platform.showNotification(
title,
text/description,
icon
);
Extensions
If you’re another extension, you want to use use Yip,
var yip = Components.classes['@foyrek.com/yip;1']
.createInstance(Components.interfaces.nsIYip);
yip.showGrowlNotification({...});
Code
Now, go try it! Load up a HTML page and just add some javascript code like
fluid.showGrowlNotification({title:"Yippie!", description:"Just testing Yip! It's awesome", icon: "http://www.google.com/favicon.ico"});
The code for Yip itself can be found on Github. Do whatever you want with it (it’s MIT licensed).
A bit of technical history
The challenge in this extension is to define a global property on every window object of every tab. This took me forever (6 months, to be precise) to figure out because it’s a tough question to phrase and because not many people want to do this. But, eventually, I did (I’ll write a bit more about how this is done in the next post). I have to thank a bunch of people on IRC for this including mfinkle, zpao, Unfocused, Mook and dolske.
Part 2
In line with my philosophy of releasing things at every useful step, I have released Yip pretty early. But be sure that there will be no sophomore slump here. Part 2 of this project is way way more exciting. But you’ll have to wait for it. Watch this project on Github in the meantime!
And because I like LOLPuppies better than LOLCats
I used to have a puppy. It died.
Photo credit to jaysonmaceo on Flickr






63 Comments
June 9, 2009 at 8:41 am
This is great, and all, but can you configure which sites you want notifications from? Honestly, I’d rather have a plugin like this on a case-by-case basis. I think it’d be a better experience for an individual site to have it’s alerts as a jetpack plugin so you had to opt-in to their messaging.
June 9, 2009 at 9:13 am
I agree you that you should be able to opt-out of certain websites (Fluid supports this and it’s definitely something that I’ll implement in the future).
But, I don’t quite agree that notifications should only be supported via plugins (then, websites would have to release separate and possibly different plugins for each browser, etc.). *Notifications need to be a part of the Web*. Websites need to be able to access the Notification API directly just like window.alert (I’m not suggesting that notifications are just replacements for alerts; they mostly definitely are not). I guess an option to turn off all notifications by default and then, ask the user to opt-in individually is a possibility. I’d argue that even this is drastic and unnecessary. Allowing notifications has no security or other implications.
June 9, 2009 at 9:40 am
That makes sense.
I guess what I’d really like to see is opt-in growl on the very top of the window..
“ActiveStudios.com would like to send you notifications. [Allow] [Ignore] [Block]”
The same kind of notification I would get if I was installing a plugin or Firefox was asking for my geo location.
June 9, 2009 at 10:00 am
Ha! Exactly what I had in mind.
I’d also have another setting that lets the user decide whether to have such notifications. So, if you’re concerned that websites will spam you, you could white-list sites with this mechanism and on the other hand, if you think the majority of webpages will behave, you black-list sites instead.
June 9, 2009 at 10:11 am
Sounds great. Call me a convert.
June 9, 2009 at 8:50 am
Awesome work, just tested with Filttr and it works just great (without any modification). The only one I can think of is to rename the section to Yip & Fluid
Btw, we @Filttr did revamp support for Fluid, just click the fluid settings on the home page to view all the options; notifications are friendlier as well.
My only request: support the “sticky” parameter?
July 20, 2009 at 5:40 pm
I’m using the nsIAlertsService, a component built into Firefox, and it doesn’t have support for “sticky”. At some point, I might rewrite it myself but for the time being, that’s why the “sticky” parameter is not available.
June 9, 2009 at 9:26 am
Who designed the cute dog logo for you?
June 9, 2009 at 10:01 am
Creative Commons.
I attributed it on the extension page (the one you get after you install the extension) but forgot to do it here.
http://www.dapino-colada.nl/?p=568
June 9, 2009 at 9:42 am
BrowserPlus Notfiy service
http://browserplus.yahoo.com/developer/services/
June 9, 2009 at 9:59 am
This seems like a really good idea! I just wanted to point out that Ubuntu has an excellent growl-esque notification system as well called notify-osd. One neat difference is that you can click right through the notifications so they can never get in the way of your work flow. There is already an extension called FirefoxNotify (https://addons.mozilla.org/en-US/firefox/addon/9622) which sends firefox notifications to the Linux notification library, so these could be a great combo!
June 9, 2009 at 10:15 am
Excellent work!
WordPress have implemented similar (but more basic) growl-like notifications in-browser for their P2 theme.
I guess they should look at supporting this instead?
June 9, 2009 at 12:37 pm
I guess the only advantage I could see here to writing a Jetpack plugin would be that you wouldn’t have to be browsing that particular page in order to receive the notification.
June 9, 2009 at 11:00 am
https://wiki.ubuntu.com/NotifyOSD
June 9, 2009 at 12:57 pm
Abi,
Yip seems pretty cool. If you’d like a domain to host project information, I’d be happy to give you some subdomains on my personal domain, yipyip.com.
June 9, 2009 at 2:05 pm
[...] You can install Yip from abi’s blog. [...]
June 9, 2009 at 3:15 pm
[...] Introducing Yip: A Unified Notification System for the Web « abi’s blogabcdefu.wordpress.com [...]
June 9, 2009 at 4:40 pm
Ah, so this is what you’ve been working on! Me like. A lot.
As a side note, you should be serving the .xpi with a MIME type of application/x-xpinstall
June 9, 2009 at 5:52 pm
Is there anyway I can use this to get all kinds of Firefox notifications + Twitterfox Updates? (I was looking for something like this yesterday but didn’t find
)
June 10, 2009 at 12:17 am
@saari I didn’t realise that BrowserPlus support notifications. Cool! I’ll support it soon. Do any Yahoo! websites make use of the BrowserPlus notifications? It would be awesome if del.icio.us or Yahoo! Mail did.
@Blair Changed the MIME type.
@Daniel Thanks a bunch for that generous offer!
June 10, 2009 at 3:32 am
I’m not sure what Fluid and Prism do, but it would be great if the icon URL could be relative, rather than absolute.
I develop web apps that are usually installed in a customer’s intranet, so the hostname and path changes from installation to installation. Being able to point to an icon relative to the page’s URL would save me having to calculate the location in script.
June 10, 2009 at 11:19 am
Hey there,
Very cool idea — great that you leveraged Fluid’s API rather than coming up with a new one (we support both Fluid & Prism’s notifications, but default to Fluid).
Mike K
UX Design @ Meebo
June 10, 2009 at 4:13 pm
[...] Introducing Yip: A Unified Notification System for the Web It’s 2009 and no browser vendor supports notifications for Webapps. The revolution begins today. Let me first [...] [...]
June 11, 2009 at 11:32 am
[...] or check out the FirefoxNotify extension for Ubuntu’s new notifications system. Introducing Yip: A Unified Notification System for the Web [abi's blog] Share and [...]
June 11, 2009 at 11:47 am
“If you know any other API, let me know in the comments and I’ll support it.”
how about Growl for Windows? the Growl/GNTP Firefox extension allows something similar (allows Greasemonkey scripts and page scripts to send notifications) and the user can control the notifications from a single place – just like on the Mac.
currently, the API is based on the GNTP spec that the Growl (Mac) guys are working for their future releases, so supporting it now will get Windows and Mac support with one API. and since there is already a Firefox extension that handles the actual sending, it would be easy to wrap with the Fluid/Prism-compatible interface.
http://groups.google.com/group/growl-for-windows/browse_thread/thread/ea7cd82177f98a9a
https://addons.mozilla.org/en-US/firefox/addon/11611
June 11, 2009 at 12:09 pm
I use meebo a lot.
and this is a pretty nice tool thanks, also) can you make it work for meebo chatrooms too? :]
June 11, 2009 at 12:21 pm
There’s something called Growl For Windows, and it would be great if these two applications could work together (http://growlforwindows.com/gfw/)
June 11, 2009 at 2:05 pm
+1
June 12, 2009 at 1:06 am
++1 (or is that just +1? or 1++?)
July 20, 2009 at 5:41 pm
Coming real soon…
June 11, 2009 at 3:42 pm
This extension is fantastic!
Any chance of future versions integrating with Snarl (Windows) and/or libnotify (Ubuntu)?
June 11, 2009 at 5:00 pm
[...] [Lifehacker] | Download Yip Unified Notification System Also Read Mumbles Brings Growl-like Notifications to your Gnome/Ubuntu DesktopFirefox extension – [...]
June 11, 2009 at 7:13 pm
Another vote for integration with the new Ubuntu Growl-like notification system.
June 11, 2009 at 11:29 pm
the link for the slew of Greasemonkey userscripts .. does that work in firefox+Xp .. fluid is OSX only right?
June 12, 2009 at 5:05 am
[...] Yip es una extensión de Firefox que soporta los estándares de notificación de Prism y Fluid e implementa sus API, de modo que el sistema es compatible con Mac OS X, Windows y Linux, y para comenzar a utilizarlo solo hay que descargar la extensión y -llegado el caso- descargar scripts de Greasemonkey para habilitar más aplicaciones con Yip. [...]
June 12, 2009 at 9:52 am
@Mike Krieger Meebo is awesome. Rock on. How about more granular preferences for the notifications?
@Andy & HeartBurnKid, the Ubuntu guys seem pretty excited about Yip. So, I’m hoping to get notify-osd integration with Yip. Do submit a patch if you can.
[1] https://lists.launchpad.net/ayatana/msg00223.html
@Mohamed Yes, Fluid is OS X only. But Yip ports the Fluid API to Firefox so those userscripts will work on Windows, Ubuntu and every other platform where Firefox runs. Try it one of the scripts out!
@Christo, Gregory and roryok Yes! I’d love to add support for Growl for Windows. I’ll try to look at it soon but i have finite time. Yip is open source and contribute it if you can.
@brian dunnington Growl for Windows sounds great. Thanks for the links.
June 12, 2009 at 10:52 am
[...] Yip è un sistema di notifiche per applicazioni web: si tratta di una estensione per Firefox che ti [...]
June 13, 2009 at 8:42 am
[...] Puedes instalarte Yip, desde el blog de Abi. [...]
June 16, 2009 at 9:00 am
[...] sticking with a desktop Twitter client for now, is the notifications. If Tweetmeme can integrate Yip, Growl via Fluid, or some other desktop notification system – I’m all in (providing it [...]
June 17, 2009 at 5:00 am
[...] http://abcdefu.wordpress.com/2009/06/09/introducing-yip-an-unified-notification-system-for-the-web/ : une extension Firefox qui unifie les systèmes de notification [...]
June 17, 2009 at 12:53 pm
Hi,
I’m not sure what I’m doing wrong. I created a greasemonkey script with the following:
(function(){
fluid.showGrowlNotification({title:”Yippie!”});
})();
This yields errors in the Error Console that say “Illegal value.” If I just put the fluid.showGrowlNotification command in the Code text field, it produces the Firefox notifications just fine.
I am running Firefox on Windows XP.
Sorry if this is not the proper place to ask about this. I didn’t know where else to ask.
July 9, 2009 at 9:39 pm
I’m getting the same Illegal Error in GreaseMonkey scripts. I’ve tried playing with the extensions.ini/extensions.cache to change the order they are loaded in and that doesn’t change anything. If it’s part of the original HTML code it works fine (so Meebo notifcations work), but GreaseMonkey scripts do not.
October 28, 2009 at 2:56 pm
Use ‘unsafeWindow.fluid’ instead of ‘window.fluid’ in greasemonkey scripts.
I figured this out by studying this script:
http://userscripts.org/scripts/review/55617
Works in FF on linux (Gnome) anyway
Hope this helps,
Chris
June 18, 2009 at 10:13 am
This seems to steal focus from the Fever newsreader web app – http://www.feedafever.com/. If you have this extension installed none of the keyboard shortcuts work.
June 25, 2009 at 1:33 am
[...] Yip is a plugin for Firefox which allows website to push notifications, through Growl in MacOS and through Firefox in everything else. You can read more about the YIP plugin, and download it on the homepage. [...]
July 5, 2009 at 9:10 pm
[...] I didn’t bother too much about it, except maybe mention it to a couple of people. Last month, Abimanyu finally came up with Yip1 which he had been working on for quite a while, and it does exactly that. But, it was for [...]
July 8, 2009 at 9:29 pm
[...] There should be a uniform way for web applications to talk users. With the release of Growler and Yip (although with a misleading by-line), there is now an interesting but expected conundrum. Like any [...]
July 14, 2009 at 7:03 am
[...] Yip [...]
July 15, 2009 at 4:42 pm
[...] post about visual notifications in OS X using Fluid+Growl. Soon after that, a developer named Abi released Yip, a Firefox extension that ports the Fluid and Prism notification APIs to Firefox. What does that [...]
July 16, 2009 at 12:40 pm
I wish there’s one for Maxthon
July 16, 2009 at 4:39 pm
[...] head over to the Yip homepage and install the plugin to see what sites are pushing notifications that you didn’t even know [...]
July 17, 2009 at 6:11 am
This is great – thank you very much. You mention notify-osd; would you consider looking at KDE’s notification system as well, for those of us not using GNOME? Cheers!
July 17, 2009 at 4:40 pm
I can confirm this works with Meebo and Seamonkey 2.0a3, too.
July 19, 2009 at 10:45 am
Hey Abi! I was reading the latest Meeblog entry–saw “Abi”, was surprised to know that it’s the Abi I know (though I shouldn’t have been surprised, right
) Good job.
July 19, 2009 at 6:30 pm
Another vote for NotifyOSD — since it implements the *first* notifications standard!
(Ok, ok, so it’s a pretty close call…)
July 20, 2009 at 5:50 pm
Haha, thanks Fiona.
@cappy It should work on any xulrunner application but did you have to modify the install.rdf file? I believe I restricted it to only Firefox (by mistake). Will change that. Seems like it would be very useful for Songbird + thesixtyone[1] when thesixtyone starts using browser notifications.
[1] http://www.thesixtyone.com
@Earle Does KDE’s notification system use libnotify? If it does, it should be easy to integrate. I’ll have to check it out.
@George Yep, NotifyOSD is great. I’m almost done with Yip 0.2 which adds support for NotifyOSD, Growl for Windows and Snarl. I’ll be releasing it as soon as my flu goes away….
July 22, 2009 at 1:38 am
Works like a charm, with one exception. I have a 2 screen setup and when firefox is on the second screen, the popup still is on the first one. Any chance of this being a small & quick fix? =)
July 25, 2009 at 3:24 am
[...] Yip: If you’re using something like meebo.com for instant messaging you surely would like to get notifications of a new message also outside the tab in your browser, as it mostlikely happens that you’re working with an other program or in an other tab. If so, take a look at Yip, as its supports supports Fluid and Prism which cover the large majority (100%?) of currently implemented notifications. In General, IT Security, Linux | No Comments [...]
July 26, 2009 at 5:35 am
Anyone able to get this working with Gmail chat notifications? It doesn’t seem to be working with the script found here: http://userscripts.org/scripts/show/42217
August 9, 2009 at 6:51 pm
[...] relatively new Yip extension for Firefox adds notification functionality. This is not a small JavaScript notification that pops [...]
August 12, 2009 at 12:29 am
[...] leider nicht genannt. Webentwickler, die Benachrichtungen in ihre Webseite einbauen wollen, finden hier Hinweise zur [...]
August 18, 2009 at 6:10 am
First, thanks for the great plugin. It works great with Growl for Windows. I have one problem though. It seems that the plug in doesn’t handle 2 byte languages (e.g. Korean, Chinese, Japanese) properly. Words in those languages display fine on Windows, but they get messed up on Growl for Windows. Would you add unicode support for those languages? Thanks!
October 28, 2009 at 2:04 am
[...] de Meebo Notifier die je kan helpen. Voor Mac is het wat lastiger. Er is een plug-in voor Firefox (Yip) die notificaties gebruikt als er een nieuw bericht is. Een simpele workaround kun je vinden op [...]