Live data from Hacker News

Chrome Extension Programming: Illustrating a Basic Survival Skill

karpathy.ca

11–20 of 25 posts

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#11
Chrome Dev Tools have become powerful enough to do some decent debugging for extensions, but does anyone know if it can be used to create them? If there is some sort of sandboxing to prevent such things, how much code would have to be changed to have Chrome join the list of self-extensible systems?

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#12
It looks like this kind of practice is quite popular. I recently created a Chrome extension to extend Airbnb listings to show crime statistics and nearby photos from Flickr.

I've shared it on the Chrome web store and GitHub on the off-chance it's of interest to anyone else https://chrome.google.com/webstore/detail/crime-stats-and-ph...

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#13

Chrome Dev Tools have become powerful enough to do some decent debugging for extensions, but does anyone know if it can be used to create them? If there is some sort of sandboxing to prevent such things, how much code would have to be changed to have Chrome join the list of self-extensible systems?

You can already write dev tools extensions. Or did you mean something else? http://developer.chrome.com/extensions/devtools.html

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#14
post #13

Chrome Dev Tools have become powerful enough to do some decent debugging for extensions, but does anyone know if it can be used to create them? If there is some sort of sandboxing to prevent such things, how much code would have to be changed to have Chrome join the list of self-extensible systems?

You can already write dev tools extensions. Or did you mean something else? http://developer.chrome.com/extensions/devtools.html

That's cool but I meant the ability to get an idea for an extension, create it, and load it without leaving Chrome. Chrome already has Codemirror and some ability to store files using snippets, so why not extend that to create things?

I realize this an exceptional use case but it'd be great to see Chrome fit Steve Yegge's QWAN concept, where one of the ideas is that a system should be modifiable and extendible without rebooting, much like Emacs (Chrome is so close to being there it hurts, but is likely intentionally prevented from working that way).

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#15

If all you want to do is execute your own js on a certain web page, you can just use greasemonkey or another userscript extension for your browser instead of writing a whole new extension each for each script. Greasemonkey also appears to provide an interface for peristent local storage as well. [1] [1] http://wiki.greasespot.net/GM_setValue

The lay user is probably more likely to install a chrome extension than code. Then again, I don't know if greasemonkey has gotten more lay-friendly recently.

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#16

If all you want to do is execute your own js on a certain web page, you can just use greasemonkey or another userscript extension for your browser instead of writing a whole new extension each for each script. Greasemonkey also appears to provide an interface for peristent local storage as well. [1] [1] http://wiki.greasespot.net/GM_setValue

The lay user is probably more likely to install a chrome extension than code. Then again, I don't know if greasemonkey has gotten more lay-friendly recently.

All they'd have to do is click a link that says "install this script" and then gm prompts you to install it.

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#18

It looks like this kind of practice is quite popular. I recently created a Chrome extension to extend Airbnb listings to show crime statistics and nearby photos from Flickr. I've shared it on the Chrome web store and GitHub on the off-chance it's of interest to anyone else https://chrome.google.com/webstore/detail/crime-stats-and-ph...

OT You're not from Shoreditch, by chance?

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#19
I do this too, though often with bookmarklets or with a plugin that runs JS on certain URLs.

One annoyance though is when the website changes their code. E.g. often CSS class names are shortened/compiled and will change with every update of the website.

Does anyone have tips how to handle that, that is, ways to get the right element without depending on the exact classname?

Re: Chrome Extension Programming: Illustrating a Basic Survival Skill

#20
post #18

It looks like this kind of practice is quite popular. I recently created a Chrome extension to extend Airbnb listings to show crime statistics and nearby photos from Flickr. I've shared it on the Chrome web store and GitHub on the off-chance it's of interest to anyone else https://chrome.google.com/webstore/detail/crime-stats-and-ph...

OT You're not from Shoreditch, by chance?

Nope, I'm not too far from Birmingham.
Post reply on HN