Re: [whatwg] Storage Standard

2015-05-04 Thread Jonas Sicking
On Mon, May 4, 2015 at 9:54 PM, Anne van Kesteren  wrote:
>> More specifically, I'm proposing to remove the persistentPermission()
>> function in favor of using navigator.permissions.query({ name:
>> "persistent-storage" });
>
> Okay, I defer to e.g. these recent threads
>
>   https://github.com/w3c/push-api/issues/136
>   https://github.com/slightlyoff/BackgroundSync/issues/39
>
> where we decided to keep similar APIs.

Having both the separate permissions API as well as the APIs from the
two threads above is nuts. We should either reverse these two APIs
above, or nuke the permissions API. The fact that Google is pushing to
have both makes no sense at all to me.

Having a single consistent API makes more sense to me. A good reason
why is the recent thread about "default" vs. "prompt". Whatever we
decide that the color of the bikeshed should be, having a single API
ensures that the color is consistent.

/ Jonas


Re: [whatwg] Storage Standard

2015-05-04 Thread Anne van Kesteren
On Mon, May 4, 2015 at 9:47 PM, Jonas Sicking  wrote:
> By "this" I mean "the API discussed in this thread" :)

Well this thread is for the Storage Standard, which has several APIs.


> More specifically, I'm proposing to remove the persistentPermission()
> function in favor of using navigator.permissions.query({ name:
> "persistent-storage" });

Okay, I defer to e.g. these recent threads

  https://github.com/w3c/push-api/issues/136
  https://github.com/slightlyoff/BackgroundSync/issues/39

where we decided to keep similar APIs.


-- 
https://annevankesteren.nl/


Re: [whatwg] Storage Standard

2015-05-04 Thread Jonas Sicking
On Mon, May 4, 2015 at 1:58 AM, Anne van Kesteren  wrote:
> On Fri, May 1, 2015 at 9:40 PM, Jonas Sicking  wrote:
>> Can't we use the permission API [1] for this? I.e. use the permission
>> name "persistent-storage" or some such? So rather than "default" we're
>> return "prompt".
>>
>> [1] https://w3c.github.io/permissions/
>
> I'm sorry, what do you mean by "this"?

By "this" I mean "the API discussed in this thread" :)

More specifically, I'm proposing to remove the persistentPermission()
function in favor of using navigator.permissions.query({ name:
"persistent-storage" });

> I filed an issue a while back
> on that specification for trying to needlessly change terminology:
>
>   https://github.com/w3c/permissions/issues/25

I'll comment there, but either way this seems like a bikeshed issue
that's not enough to kill the permissions spec.

> If you mean persistentPermission() by this, the reason that is there
> is because we have done the same thing for other new APIs, such as the
> Push API.

In the past we didn't have the navigator.permissions API. Now we do.

/ Jonas


Re: [whatwg] Storage Standard

2015-05-04 Thread Anne van Kesteren
On Fri, May 1, 2015 at 9:40 PM, Jonas Sicking  wrote:
> Can't we use the permission API [1] for this? I.e. use the permission
> name "persistent-storage" or some such? So rather than "default" we're
> return "prompt".
>
> [1] https://w3c.github.io/permissions/

I'm sorry, what do you mean by "this"? I filed an issue a while back
on that specification for trying to needlessly change terminology:

  https://github.com/w3c/permissions/issues/25

If you mean persistentPermission() by this, the reason that is there
is because we have done the same thing for other new APIs, such as the
Push API.


-- 
https://annevankesteren.nl/


Re: [whatwg] Storage Standard

2015-05-01 Thread Jonas Sicking
Can't we use the permission API [1] for this? I.e. use the permission
name "persistent-storage" or some such? So rather than "default" we're
return "prompt".

[1] https://w3c.github.io/permissions/

/ Jonas

On Fri, May 1, 2015 at 5:11 AM, Anne van Kesteren  wrote:
> Based on the discussion on this list and on:
>
>   https://wiki.whatwg.org/wiki/Storage
>   https://github.com/slightlyoff/StorageDurability
>
> Here's a first draft:
>
>   https://storage.spec.whatwg.org/
>   https://github.com/whatwg/storage
>   https://twitter.com/storagestandard
>
> It does not address multiple boxes for now. I hope we can continue
> discussing those in parallel, perhaps in the GitHub repository, as
> they are important to the gaming industry. Boxes can really help in
> the case where the site is trying to do the right thing and wants to
> avoid prompting the user, and also would allow introducing new global
> strategies such as an actual API-exposed cache (service workers' Cache
> API is all-or-nothing like any other API), or boxes with a max-age.
>
>
> --
> https://annevankesteren.nl/


Re: [whatwg] Storage Standard

2015-05-01 Thread delfin
 

:) ! 

Is it ready to be spread? 

---

Delfi Ramirez

My digital signature [6]

+34 633 589231
 del...@segonquart.net [7] 

twitter: delfinramirez

 IRC: segonquart Skype: segonquart [8]

http://segonquart.net [9]

http://delfiramirez.info
 [10]

On 2015-05-01 14:11, Anne van Kesteren wrote: 

> Based on the discussion on this list and on:
> 
> https://wiki.whatwg.org/wiki/Storage [1]
> https://github.com/slightlyoff/StorageDurability [2]
> 
> Here's a first draft:
> 
> https://storage.spec.whatwg.org/ [3]
> https://github.com/whatwg/storage [4]
> https://twitter.com/storagestandard [5]
> 
> It does not address multiple boxes for now. I hope we can continue
> discussing those in parallel, perhaps in the GitHub repository, as
> they are important to the gaming industry. Boxes can really help in
> the case where the site is trying to do the right thing and wants to
> avoid prompting the user, and also would allow introducing new global
> strategies such as an actual API-exposed cache (service workers' Cache
> API is all-or-nothing like any other API), or boxes with a max-age.
 

Links:
--
[1] https://wiki.whatwg.org/wiki/Storage
[2] https://github.com/slightlyoff/StorageDurability
[3] https://storage.spec.whatwg.org/
[4] https://github.com/whatwg/storage
[5] https://twitter.com/storagestandard
[6] http://delfiramirez.info/public/dr_public_key.asc
[7] mail:%20del...@segonquart.net
[8] skype:segonquart
[9] http://segonquart.net
[10] http://delfiramirez.info