question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Question about preloading excluded assets

See original GitHub issue

I have a small app using vitesse template (that uses this plugin) and I have a problem with some SVG images that are not included on assets directory (are too big to be inlined, and then vite just set its href to undefined, so I moved them to public directory), but then, this plugin excludes these images from PWA, or at least once installed (PWA on client), these SVG are not downloaded (and when testing offline, just alt attribute are displayed instead SVG).

I’m looking to use prefetching these SVG once the page is requested, but the problem pages are served from external server (webflux kotlin server with freemarker template) and the rest of pages are excluded (I have 4 pages, one containing a subgroup of these SVG and another containing other subgroup of these SVG). Maybe preloading all pages via html link will work (I’ve not test yet)?

I use server push on server side once each page is requested using vite manifest.json file, so when requesting a page all resources are just cached.

Is there a way to include some prefetch via these plugin to hook into the workbox or I just need to use Cache Storage API?

Another question is about user feedback: How to integrate with these plugin?

Any suggestions are welcome.

Thx in advance.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
userquincommented, Dec 24, 2020

Thx @antfu, I close this, I need to investigate and I feed back you when I have tried to fix inclusion of external resources bundle.

I’ll try to do something similar to rollap-plugin-gzip that allows to compress resources outside bundle: Configuration see additionalFiles entry.

1reaction
userquincommented, Dec 24, 2020

missing one n from the name?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Resources preloads without question? (High memory usage)
The question is, how do I prevent unity from preloading the Resources folder assets from the hard drive and get myself to do...
Read more >
Preloading assets in React-Native expo app never finishes
I have excluded my react-navigation code for the sake of brevity. When I run this, my app gets stuck at Downloading JavaScript bundle...
Read more >
is there a way to preload specific images for desktop users ...
PNG images because it would be too much loading time for a phone. This leads to my question: Is there a way to...
Read more >
Preload critical assets to improve loading speed - web.dev
Blocking the display of fonts without a fallback can be considered a user experience problem. On one hand, loading fonts with font-display: ...
Read more >
Caching plugin causing preloader to load after page starts to ...
[This thread is closed.] Hi, I just installed the plugin and notice that it my page elements are visibly loading before the preloader...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found