summaryrefslogtreecommitdiff
path: root/packages/integrations/prefetch/test (follow)
AgeCommit message (Collapse)AuthorFilesLines
2023-08-01Fix prefetch test fail (#7902)Gravatar Bjorn Lu 1-0/+2
2023-07-07Updates prefetch integration to add "only prefetch link on ↵Gravatar Kory Smith 6-5/+267
hover/mouseover/focus" option (#6585) * modifies prefetch to add the option to only prefetch certain pages on hover * adds new pages to the test website to showcase prefetch-intent functionality * adds tests to verify prefetch-intent behavior * adds changelog * waits until networkidle to check if the prefetching worked instead of waiting on a specific url load * allows intentSelector to be either a string or array of strings * Revert "allows intentSelector to be either a string or array of strings" This reverts commit b0268eb0d5220ad2b08b0b7aee23f43e4caf879f. * fixes the multiple selector logic and adds tests * updates docs to include new prefetch-intent integration * Update packages/integrations/prefetch/README.md Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca> * Update packages/integrations/prefetch/README.md Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca> * Update packages/integrations/prefetch/README.md Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca> * Update .changeset/little-cars-exist.md Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca> * Update packages/integrations/prefetch/README.md Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca> --------- Co-authored-by: Erika <3019731+Princesseuh@users.noreply.github.com> Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com> Co-authored-by: Sarah Rainsberger <sarah@rainsberger.ca> Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
2023-07-03feat: use typescript-eslint@v6's reworked configs (#7425)Gravatar Josh Goldberg ✨ 1-2/+1
2023-04-13Ensure unique workspace name (#6836)Gravatar Bjorn Lu 1-1/+1
2023-01-09Default preview host to localhost (#5753)Gravatar Bjorn Lu 3-5/+5
* Initial refactor * Extract as vite plugin * Cleanup vite plugin * Reduce option passing * Use localhost as preview default host * Simplify base handling * Fix host handling * Add changeset * Remove unused imports * Remove unused sirv dep * Try pin playwright to 1.28.1 * Update playwright * Try this * Speed up CI * Try fix page off * Refactor networkidle * Ensure open connections are destroyed when the preview server is closed * Revert debug code Co-authored-by: Matthew Phillips <matthew@matthewphillips.info>
2022-10-19[ci] formatGravatar matthewp 1-3/+3
2022-10-19Prefetch styles only once (#5125)Gravatar Jelenkee 6-0/+119
* test1 * fixed test * removed console.log * changeset * pnpm-lock * fixed test again * fta * fta2 * fix: wait for fetch * -fixed test template * empty Co-authored-by: Matthew Phillips <matthew@skypack.dev> Co-authored-by: Nate Moore <nate@astro.build> Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com> Co-authored-by: My Name <my.name@my-company.com>
2022-10-07[@astrojs/prefetch]: Prevent prefetching current page (#5009)Gravatar Oskar Baumann 3-30/+43
* Check that removal of url.hash breaks no tests * test if status-quo is as expected * Adapt tests to fail * Adapt the shouldPreload function to skip same path * Add changeset
2022-06-27[ci] formatGravatar tony-sull 2-8/+26
2022-06-27Adds a prefetch integration for near-instant page navigations (#3725)Gravatar Tony Sullivan 9-0/+242
* Adds a basic @astrojs/prefetch integration * adding tests for custom selectors * missed in last commit * Adding a few docs, removing the option for `selectors` to be an element array * adding an option for the concurrency limit * fixing test for updated integration options * Update packages/labs/prefetch/src/client.ts Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com> * nit: removing the NodeJS.Timer type to allow typescript to infer the return * updating docs for default selector with ~= * Skip prefetching on 2G connections, or when data saver is enabled * refactor: moving to packages/integrations, Astro Labs TBD down the road * README typo fix Co-authored-by: Nate Moore <natemoo-re@users.noreply.github.com>