Re: Service Workers at Work...

Google's SW-toolbox has limitations, but it's very handy nonetheless.
dan

On 24 Oct 2016 3:39 pm, "Ivan Herman" <ivan@w3.org> wrote:

>
> On 24 Oct 2016, at 16:17, Hadrien Gardeur <hadrien.gardeur@feedbooks.com>
> wrote:
>
> The trick is in
>>
>> https://hpbn.co/assets/5e7a4451127bdccbb9346f1c8744c0d9.js
>>
>
> Well, actually most of the magic is in: https://hpbn.co/service-worker.js
> This is based on sw-toolbox which is pretty convenient when you don't want
> to write your SW yourself.
>
> Basically there are only two lines for the configuration, the rest is the
> code for sw-toolbox itself:
>
>
> <snip>long line, essentially the table of content I guess</snip>
>
>
> var cacheName = 'sw-precache-v2-hpbn-' + (self.registration ? self.registration.scope : '');
>
> Good to know it is that simple!
>
> Ivan
>
> ----
> Ivan Herman, W3C
> Digital Publishing Technical Lead
> Home: http://www.w3.org/People/Ivan/
> mobile: +31-641044153
> ORCID ID: http://orcid.org/0000-0003-0782-2704
>
>
>
>
>

Received on Monday, 24 October 2016 14:42:09 UTC