astro/packages/integrations
Tony Sullivan e8593e7ead
Adds an @astrojs/image integration for optimizing images (#3694)
* initial commit

* WIP: starting to define interfaces for images and transformers

* WIP: basic sharp service to test out the API setup

* adding a few tests for sharp.toImageSrc

* Adding tests for sharp.parseImageSrc

* hooking up basic SSR support

* updating image services to return width/height

* simplifying config setup for v1

* hooking up basic SSR + SSG support (dev & build)

* refactor: a bit of code cleanup and commenting

* WIP: migrating local files to ESM + vite plugin

* WIP: starting to hook up user-provided loaderEntryPoints

* chore: update lock file

* chore: update merged lockfile

* refactor: code cleanup and type docs

* pulling over the README template for first-party integrations

* moving metadata out to the loader

* updating the test for the refactored import

* revert: remove unrelated webapi formatting

* revert: remove unrelated change

* fixing up the existing sharp tests

* fix: vite plugin wasn't dynamically loading the image service properly

* refactor: minor API renaming, removing last hard-coded use of sharp loader

* don't manipulate src for hosted image services

* Adding support for automatically calculating dimensions by aspect ratio, if needed

* a few bug fixes + renaming the aspect ratio search param to "ar"

* Adding ETag support, removing need for loaders to parse file metadata

* using the battle tested `etag` package

* Adding support for dynamically calculating partial sizes

* refactor: moving to the packages/integrations dir, Astro Labs TBD later

* refactor: renaming parse/serialize functions

* Adding tests for SSG image optimizations

* refactor: clean up outdated names related to ImageProps

* nit: reusing cached SSG filename

* chore: update pnpm lock file

* handling file URLs when resolving local image imports

* updating image file resolution to use file URLs

* increasing test timeout for image build tests

* fixing eslint error in sharp test

* adding slash for windows compat in src URLs

* chore: update lockfile after merge

* Adding README content

* adding a readme call to action for configuration options

* review: A few of the quick updates from the PR review

* hack: adds a one-off check to allow query params for the _image route

* Adds support for src={import("...")}, and named component exports

* adding SSR tests

* nit: adding a bit more comments

* limiting the query params in SSG dev to the images integration
2022-07-01 15:47:48 +00:00
..
cloudflare [ci] release (#3783) 2022-07-01 03:09:17 +00:00
deno [ci] release (#3774) 2022-06-30 11:39:44 -07:00
image Adds an @astrojs/image integration for optimizing images (#3694) 2022-07-01 15:47:48 +00:00
lit removed experimental warning from astro add command (#3727) 2022-06-27 13:44:32 -05:00
mdx [ci] release (#3774) 2022-06-30 11:39:44 -07:00
netlify [ci] release (#3774) 2022-06-30 11:39:44 -07:00
node [ci] release (#3774) 2022-06-30 11:39:44 -07:00
partytown [ci] release (#3774) 2022-06-30 11:39:44 -07:00
preact [ci] release (#3772) 2022-06-30 08:08:09 -05:00
prefetch [ci] release (#3774) 2022-06-30 11:39:44 -07:00
react removed experimental warning from astro add command (#3727) 2022-06-27 13:44:32 -05:00
sitemap [ci] release (#3774) 2022-06-30 11:39:44 -07:00
solid removed experimental warning from astro add command (#3727) 2022-06-27 13:44:32 -05:00
svelte [ci] update lockfile (#3740) 2022-06-28 08:33:13 -05:00
tailwind manual lockfile update (#3751) 2022-06-29 14:54:40 -07:00
turbolinks [ci] release (#3378) 2022-05-17 11:50:18 -04:00
vercel [ci] release (#3774) 2022-06-30 11:39:44 -07:00
vue [ci] update lockfile (#3740) 2022-06-28 08:33:13 -05:00