I've updated this to the browser actions API.

The diff is mostly deleting lines, since it is now much easier to do
this kind of thing:
  
http://neugierig.org/software/git/?url=chrome-readability/commit/&id=9768c8fa1f807f85a2387310214b7ff6b4153e1a

I was able to pack my extension and install it as well, all on Linux.

Pretty much everything was great -- my only points of confusion
follow.  I'm almost certain y'all already know about all of these, but
just in case...

 - The docs are behind the code (had to read the code once or twice to
figure out what was going wrong).
 - Not exactly clear sometimes which error console you're supposed to
look at; the workflow of "reload, see what error happened this time"
takes a few too many clicks.  Would be nice if chrome://extensions/
remembered whether I had the developer tools turned on or off.
 - Got one browser crash while developing.  But I think we've fixed
some crashers seen on the current dev channel on trunk, so I hope it
was one of those.

On Sat, Sep 12, 2009 at 7:02 PM, Evan Martin <e...@chromium.org> wrote:
> [resend, I think I screwed up the previous three tries]
> I wrote an extension that adds a page action to trigger Readability:
>  http://lab.arc90.com/experiments/readability/
>
> It's basically just a glorified bookmarklet.
>
> Code is here:
>  http://neugierig.org/software/git/?url=chrome-readability/
> Browse it here:
>  http://neugierig.org/software/git/?url=chrome-readability/tree/
>
> I can't provide a .crx because I wasn't able to figure out how to
> build one, which I think means I can't actually install it.  :~(
>
> Here's some feedback on the process.  I know extensions are still
> under development, and that surely most if not all of these are
> already known bugs, and that others are probably my fault for doing it
> on Linux.  I thought it would still be helpful to give an overview of
> points of confusion I ran into, in case any of these aren't yet known
> bugs.
>
> - Weight.
> This feels like a *lot* of code (content script, page action,
> background page, manifest, message ports) just to make a bookmarklet
> appear in the URL bar.  I wonder if there's a place for a "simple"
> extension API for bookmarklet-y sorts of things?
>
> - Making my page action show up.
> It wasn't clear to me how to make my action just always show up.
> I think I may have done it wrong:
>  http://neugierig.org/software/git/?url=chrome-readability/tree/background.html
> since it feels unreliable (sometimes it doesn't show).
>
> - The failure modes are confusing.
> Sometimes it prints to the console (when I've made a typo in my
> manifest); other times it prints to the error console of the extension
> (bugs in my background js); other times it prints to the page's error
> console (bugs in my content script).  Many of those times there's no
> obvious way to map the error back to the line that is failing.
>
> - JS console.
> Do we really have no UI to get to the JS console?  I had to open the
> developer tools, then guess that one of the icons at the bottom of
> the window would show me the messages.
>
> - The docs around content scripts communicating with the embedding
> page aren't too clear.  See e.g.:
>  http://code.google.com/chrome/extensions/content_scripts.html#messaging
> That section is mostly just a big example but for example nowhere is
> the postMessage API described.  I'd prefer it to be laid out more
> like:
>  - how to make each endpoint listen for messages
>  - how to make each endpoint send a message
>
> - Doc organization.
> It would've been clearer to me if there is one more level of nesting.
> Sections like toolstrips, page actions are features with manifest
> edits as well as APIs, while sections like tabs and windows are just
> API references.
>
> - Building the .crx.
> strace -fo log chromium-browser --user-data-dir=/home/martine/test
> --pack-extension=`pwd`/readext
> --pack-extension-key=chrome-readability.pem
> Doesn't show it ever trying to create my .pem.  Maybe it's not implemented,
> but it'd be nice if it at least complained in that case.
>

--~--~---------~--~----~------------~-------~--~----~
Chromium Developers mailing list: chromium-dev@googlegroups.com 
View archives, change email options, or unsubscribe: 
    http://groups.google.com/group/chromium-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to