diff --git a/.changeset/cyan-readers-wonder.md b/.changeset/cyan-readers-wonder.md new file mode 100644 index 000000000..c6aac0a6d --- /dev/null +++ b/.changeset/cyan-readers-wonder.md @@ -0,0 +1,5 @@ +--- +'astro': patch +--- + +Document `image.service` configuration option diff --git a/packages/astro/src/@types/astro.ts b/packages/astro/src/@types/astro.ts index d4349cf72..1100cd5f8 100644 --- a/packages/astro/src/@types/astro.ts +++ b/packages/astro/src/@types/astro.ts @@ -706,6 +706,27 @@ export interface AstroUserConfig { * @name Image options */ image?: { + /** + * @docs + * @name image.service (Experimental) + * @type {'astro/assets/services/sharp' | 'astro/assets/services/squoosh' | string} + * @default `'astro/assets/services/squoosh'` + * @version 2.1.0 + * @description + * Set which image service is used for Astro’s experimental assets support. + * + * The value should be a module specifier for the image service to use: + * either one of Astro’s two built-in services, or a third-party implementation. + * + * ```js + * { + * image: { + * // Example: Enable the Sharp-based image service + * service: 'astro/assets/services/sharp', + * }, + * } + * ``` + */ // eslint-disable-next-line @typescript-eslint/ban-types service: 'astro/assets/services/sharp' | 'astro/assets/services/squoosh' | (string & {}); }; @@ -926,6 +947,7 @@ export interface AstroUserConfig { legacy?: object; /** + * @docs * @kind heading * @name Experimental Flags * @description