Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/florian-lefebvre/astro-capo

Capo.js integration for Astro
https://github.com/florian-lefebvre/astro-capo

Last synced: 23 days ago
JSON representation

Capo.js integration for Astro

Awesome Lists containing this project

README

        

# astro-capo

> Warning
>
> POC, not production ready

Optimize head using capo.js.

## Get started

```bash
pnpm add astro-capo
```

Add a middleware and import `withCapo`:

```ts
// src/middleware.ts

import { sequence } from "astro/middleware";
import { withCapo } from "astro-capo";

export const onRequest = sequence(withCapo);
```

That's it

## Development

Having Corepack is recommended

```
pnpm i --frozen-lockfile
```

```
pnpm --filter playground dev
```