Skip to content

Commit

Permalink
Docs: add section to help those bundling via Vite
Browse files Browse the repository at this point in the history
  • Loading branch information
idchlife authored and lovell committed Feb 8, 2024
1 parent 26d0b71 commit fc439be
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
20 changes: 20 additions & 0 deletions docs/install.md
Expand Up @@ -249,6 +249,26 @@ option.
}
```

### vite

Ensure `sharp` is excluded from bundling via the
[build.rollupOptions](https://vitejs.dev/config/build-options.html)
configuration.

```js
import { defineConfig } from 'vite';

export default defineConfig({
build: {
rollupOptions: {
external: [
"sharp"
]
}
}
});
```

## TypeScript

TypeScript definitions are published as part of
Expand Down

0 comments on commit fc439be

Please sign in to comment.