Wat is Speculation Rules Generator?
Speculation Rules Generator is een browsertool voor deze taak: Genereer Speculation Rules JSON voor prerendering en prefetching in Chrome en Edge. De uitvoer blijft leesbaar, zodat je die kunt controleren voordat je hem publiceert.
Quick answer
Speculation Rules use JSON to tell Chrome and Edge which pages to prefetch or prerender before the user clicks. Prerender loads the full page for instant navigation; prefetch fetches only the main document.
Limitations
- Speculation Rules only work in Chrome and Edge. Other browsers ignore the script tag entirely.
- Eager prerendering of many pages can waste significant bandwidth and memory, especially on mobile devices.
- Cross-origin prerendering has strict privacy constraints. Browsers may strip cookies and storage access from cross-origin prerendered pages.
Zo gebruik je deze tool
- Open de tool en vul de relevante waarden in.
- Controleer de uitvoer in het resultaatpaneel.
- Kopieer alleen het deel dat bij je página past.
- Test de wijziging voordat je publiceert.
Waarvoor je het kunt gebruiken
- Terugkerend publicatiewerk sneller afronden.
- Markup, CSS of checklists voorbereiden voor een launch.
- Kleine fouten vermijden die bij statische sites makkelijk worden gemist.