# @chialab/wds-plugin-polyfill

> Inject polyfills to HTML responses served by the web dev server.

Latest version **0.19.1** (published 2026-02-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install @chialab/wds-plugin-polyfill
pnpm add @chialab/wds-plugin-polyfill
yarn add @chialab/wds-plugin-polyfill
bun add @chialab/wds-plugin-polyfill
```

## Health

**Score 60/100 (C)** — status: stable.

Positive: has types; esm support; no vulnerabilities; has provenance.

Warnings: low downloads; pre 1.0.

## Facts

| | |
|---|---|
| Version | 0.19.1 |
| Published | 2026-02-25 |
| First published | 2021-05-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=18 |
| Dependencies | 1 |
| Unpacked size | 5.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 183 |
| Author | Chialab |
| Maintainers | chialab-admin, chialab-developers |
| Keywords | dev-server, plugin, polyfill, polyfill.io |

## Links

- npm: https://www.npmjs.com/package/@chialab/wds-plugin-polyfill
- Repository: https://github.com/chialab/rna
- Homepage: https://github.com/chialab/rna#readme
- Issues: https://github.com/chialab/rna/issues
- npm.io page: https://npm.io/package/@chialab/wds-plugin-polyfill

## Dependencies (1)

- [polyfill-library](https://npm.io/package/polyfill-library.md) ^4.8.0

## Recent versions

- 0.19.1 (latest) — 2026-02-25
- 0.19.0-beta.0 (beta) — 2024-03-11
- 0.18.0-alpha.1 (alpha) — 2023-08-29
- 0.19.0 — 2025-08-25
- 0.18.0 — 2024-01-11
- 0.18.0-alpha.0 — 2023-05-01
- 0.17.0 — 2022-08-23
- 0.16.0 — 2022-06-08
- 0.15.28 — 2022-05-10
- 0.15.13 — 2022-03-29
- 0.15.3 — 2022-03-04
- 0.15.2 — 2022-03-04
- 0.15.0 — 2022-03-01
- 0.15.0-alpha.1 — 2022-02-21
- 0.14.17 — 2022-02-02
- … 17 more at https://npm.io/package/@chialab/wds-plugin-polyfill/versions

## README

# Wds Plugin Polyfill

Inject polyfills to HTML responses served by the [Web Dev Server](https://modern-web.dev/docs/dev-server/overview/).

> [!CAUTION]
> Since we are moving away from the RNA cli, we are discontinuing the development of Web Dev Server plugins.

[![NPM](https://img.shields.io/npm/v/@chialab/wds-plugin-polyfill.svg)](https://www.npmjs.com/package/@chialab/wds-plugin-polyfill)

## Install

```sh
npm i @chialab/wds-plugin-polyfill -D
```

```sh
yarn add @chialab/wds-plugin-polyfill -D
```

```sh
pnpm add @chialab/wds-plugin-polyfill -D
```

## Usage

```js
import { polyfillPlugin } from '@chialab/wds-plugin-polyfill';
import { startDevServer } from '@web/dev-server';

await startDevServer({
    plugins: [
        polyfillPlugin({
            minify: true,
            features: {
                'URL': {},
                'URL.prototype.toJSON': {},
                'URLSearchParams': {},
                'Promise': {},
                'Promise.prototype.finally': {},
                'fetch': {},
            },
        }),
    ],
});
```

It uses the [polyfill.io](https://github.com/Financial-Times/polyfill-library) library under the hoods.

## License

**Wds Plugin Polyfill** is released under the [MIT](https://github.com/chialab/rna/blob/main/packages/wds-plugin-polyfill/LICENSE) license.

---
_Source: https://npm.io/package/@chialab/wds-plugin-polyfill · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
