Lahcen Bensaad

Results 28 comments of Lahcen Bensaad

Thank you @maiieul, I have succeeded to make workbox download the whole build folder, but the problem is that it makes 332 requests because qwik generates so many js files....

Many thanks @gioboa, That is exactly what I needed. Now I have 82 requests instead of 332, and it takes 9 seconds to download all files instead of 35 s.

I think Qwik needs Workbox integration. Maybe @eric-burel can help with that.

Thanks a lot @Aslemammad, it is working and clean. I had to add this `setDefaultHandler(new NetworkFirst());` in the service worker so that calls to `/api/` are also cached for offline.

@Aslemammad this is what I added in the service worker: ``` import { NetworkFirst } from 'workbox-strategies'; import { setDefaultHandler } from "workbox-routing"; setDefaultHandler(new NetworkFirst()); ``` The NetworkFirst strategy is...

@Aslemammad I have tried this code and also worked ``` registerRoute( ({ url }) => url.pathname.startsWith('/api/'), new NetworkFirst() ); ```

Because we are prefething every thing, I think it is better also to change the bundling strategy of qwikVite from default 'smart' to 'single', that will produce one js file...

@Aslemammad for each route, qwik generates a `q-data.json` file next to `index.html`. Those files need to be pre-fetched also. qwik can not route to those routes offline if you did...

Thanks, are there any docs about v2 and breaking changes to start preparing for it or testing it?

Great, thank you @ianlet, any ETA for v2?