[whatwg] HTML Cookie API

On Thu, Feb 25, 2010 at 6:54 AM, Diogo Resende <dresende at thinkdigital.pt>wrote:

> On Wed, 2010-02-24 at 11:21 -0800, Darin Fisher wrote:
> > For reference, reading document.cookie has measurable performance cost
> > in Chromium since the cookie jar lives in a process separate from the
> > process running JavaScript.  We could have minimized this cost by
> > caching the cookies locally, but then there are cache coherency
> > issues.
> >
> >
> > I think the cookie APIs should have been asynchronous from the start.
> >  Whenever an API is backed by I/O, asynchronous should be the rule.
> >
> >
> > -Darin
>
> What about something like:
>
> document.pushCookies(function () {
>        // cookies have been pushed to the js process
>        var x = document.getCookie("x");
>        // whatever...
> });
>
>
This seems similar to Adam's proposed document.getAllCookies.

-Darin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20100225/f52e007f/attachment-0001.htm>

Received on Thursday, 25 February 2010 08:47:00 UTC