5 ms·
Safari 5 Extension Development
- OoTheNigerian 16y agoI am no coder so pardon my naive question. Is it possible for chrome and safari extensions to be interoperable, especially as they both have the same underlying web-kit technology? Surely, we do not want another platform fragmentation and battle. I am sure developers would love do no more work than recompiling the extension they built for Chrome. It will be a win for everyone.
- Dirt_McGirt 16y agoNope, different interfaces to the underlying webkit functionality. And they're packed up differently. I suppose the core functionality of more advanced extensions could be shared, with only different interface glue, but with simple ones, it won't be worth the bother to try to share.
- lenni 16y agoThere is no technical reason why this couldn't work, but my guess is that abstraction libraries will be necessary because Apple and Google won't be able to a agree on a common API. I kinda agree because having to standardise HTML, CSS and JS is hard enough and the browser makers don't wanna open up another battle front. Also, being able to tailor the API tightly to the underlying browser will attract developers and therefore enable more competition. Good times for add-on developers!
- Kilimanjaro 16y agoIn the same vein of commonJS, they should get together and create commonXT
- Derferman 16y agoI wrote a really simple extension that injects jQuery into the current webpage. Not very practical as the same features can be found in a bookmarklet, but fun to make nonetheless. http://conroy.posterous.com/jqueried-a-safari-5-extension http://conroy.posterous.com/jqueried-a-safari-5-extension
- sirn 16y agoInteresting, in the Messages and Proxies[1] page, Apple has ad-blocking as an example which actually blocks the ads from being loaded using the `beforeload` event (as oppose to hide them after they're loaded): > Safari 5.0 and later (and other Webkit-based browsers) generates a “beforeload” event before loading each sub-resource belonging to a webpage. The “beforeload” event is generated before loading every script, iframe, image, or stylesheet specified in the webpage, for example. Isn't this exactly what the NoScript's author says Chrome extension was lacking[2]? [1]: http://developer.apple.com/safari/library/documentation/Tools/Conceptual/SafariExtensionGuide/MessagesandProxies/MessagesandProxies.html http://developer.apple.com/safari/library/documentation/Tool... [2]: http://hackademix.net/2009/12/10/why-chrome-has-no-noscript/ http://hackademix.net/2009/12/10/why-chrome-has-no-noscript/
- ComputerGuru 16y agoCan I be honest and not be thought less of for it? I actually like Chrome's "load then hide" version of AdBlock because the ad impression counts. It doesn't do much for PPC ads, but for PPI, the website owner has "made an impression" with the ad unit. Of course, it's robbing the advertiser at the same time....
- potatolicious 16y agoI'd rather it not count. AdBlock originated out of a deep annoyance/hatred for distracting, exploitative ads - but has since grown to cover just about every advertiser out there, good and bad. Many people install AdBlock without seemingly realizing this difference. What I would like to see a much more discerning ad-blocking solution that punishes scammy, distracting, or otherwise abusive ads, and rewards advertisers that create consumer-friendly ads. With a load-then-hide system the website owner has fewer effective metrics on whether or not people are actively blocking his ads. Perhaps when his impressions start dropping precipitously he would be much more compelled to act. Of course, all of this hinges on the existence of a trusted adblock source that takes upon itself great pains to maintain a list that bans only abusive advertisers. I'm not holding my breath.
- 16y ago
- KirinDave 16y agoFor those who want to see a naive extension in action, I did a quick version of Helvetireader to the Safari extension format. It's trivial, but it also is a good template for further injection projects: http://kirindave.tumblr.com/post/675464589/safari-5-port-of-helvetireader http://kirindave.tumblr.com/post/675464589/safari-5-port-of-... My big question is: will these make it to the iPad version of Safari?
- swannodette 16y ago> My big question is: will these make it to the iPad version of Safari? I really, really hope so.
- macrael 16y agoHow does it work? I installed it but I can't find a way to activate it.
- sirn 16y agoEnable Safari's developer menu. (Preferences → Advanced → Show developer menu) Then enable extensions. (Develop → Enable Extensions)
- macrael 16y agoI got that far, but I guess I don't know what the extent ion actually does. How do i use it?
- WiseWeasel 16y agoYou then must find extensions to install. They can be downloaded from any website, and installed by the browser. Here's one repository of Safari 5 extensions I was able to find: http://safariextensions.tumblr.com/ http://safariextensions.tumblr.com/
- tzs 16y agoBefore this, how did third parties add functionality to Safari? For instance, the button 1Passwoed puts in the toolbar and the item it adds to the context menu for form fields?
- sirn 16y agoUsing InputManager[1] or SIMBL[2]. There are several things Safari Extension is not capable of due to lack of API (anything not involving webpage data) so InputManager/SIMBL-plugins are still necessary. [1]: http://www.cocoadev.com/index.pl?InputManager http://www.cocoadev.com/index.pl?InputManager [2]: http://culater.net/software/SIMBL/SIMBL.php http://culater.net/software/SIMBL/SIMBL.php
- smackfu 16y agoThey used other OS X features that weren't meant for browser extensions. That means they tend to break when Safari is updated, and Apple killed a whole class of them in Snow Leopard. And they didn't work on Windows Safari, of course.
- fortybillion 16y agoSnow Leopard broke a lot of the extensions built using Input Managers, so 1Password 3.0 used the Scripting Additions method. http://kevin.sb.org/2009/09/02/1password-extension-loading-in-snow-leopard/ http://kevin.sb.org/2009/09/02/1password-extension-loading-i...
- vladocar 16y agoAre all Safari 5 Extension will be free?
- WiseWeasel 16y agoThey're just packages that you download and install, so they could feasibly be charged for. I'm pretty sure it's impossible to hide the source code, however, so a copy would emerge almost immediately if you tried to make a market for yourself. So yes, effectively all Safari 5 extensions will be free.
- icefox 16y agoIt would be nice if you could listen for events, specifically I want to know when a tab is closed so I can add a action to re-open the last closed tab.