Skip to content

Commit

Permalink
ci: update integration docs
Browse files Browse the repository at this point in the history
  • Loading branch information
delucis authored May 3, 2023
1 parent 3ac0633 commit 5b617f6
Showing 1 changed file with 57 additions and 0 deletions.
57 changes: 57 additions & 0 deletions src/content/docs/en/guides/integrations-guide/vercel.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,63 @@ export default defineConfig({
});
```

### imageConfig

**Type:** `VercelImageConfig`<br/>
**Available for:** Edge, Serverless, Static
**Added in:** `@astrojs/vercel@3.3.0`

Configuration options for [Vercel's Image Optimization API](https://vercel.com/docs/concepts/image-optimization). See [Vercel's image configuration documentation](https://vercel.com/docs/build-output-api/v3/configuration#images) for a complete list of supported parameters.

```js
// astro.config.mjs
import { defineConfig } from 'astro/config';
import vercel from '@astrojs/vercel/static';

export default defineConfig({
output: 'server',
adapter: vercel({
imageConfig: {
sizes: [320, 640, 1280]
}
})
});
```

### imageService

**Type:** `boolean`<br/>
**Available for:** Edge, Serverless, Static
**Added in:** `@astrojs/vercel@3.3.0`

When enabled, an [Image Service](/en/reference/image-service-reference/) powered by the Vercel Image Optimization API will be automatically configured and used in production. In development, a built-in Squoosh-based service will be used instead.

```js
// astro.config.mjs
import { defineConfig } from 'astro/config';
import vercel from '@astrojs/vercel/static';

export default defineConfig({
output: 'server',
adapter: vercel({
imageService: true
})
});
```

```astro
---
import { Image } from "astro:assets";
import astroLogo from "../assets/logo.png";
---
<!-- This component -->
<Image src={astroLogo} alt="My super logo!" />
<!-- will become the following HTML -->
<img src="/_vercel/image?url=_astro/logo.hash.png&w=...&q=..." alt="My super logo!" loading="lazy" decoding="async" width="..." height="..." />
```

### includeFiles

**Type:** `string[]`<br/>
Expand Down

0 comments on commit 5b617f6

Please sign in to comment.