# jest-ts-webcompat-resolver

> A resolver for Jest that handles TypeScript imports using a `.js` extension.

Latest version **1.0.1** (published 2025-04-23) · MIT license · 0 weekly downloads

## Install

```sh
npm install jest-ts-webcompat-resolver
pnpm add jest-ts-webcompat-resolver
yarn add jest-ts-webcompat-resolver
bun add jest-ts-webcompat-resolver
```

## Health

**Score 25/100 (F)** — status: maintenance-mode.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: stale; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2025-04-23 |
| First published | 2019-04-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 4.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 21 |
| Author | Darryl Pogue |
| Maintainers | dpogue, ayogohealth |

## Links

- npm: https://www.npmjs.com/package/jest-ts-webcompat-resolver
- Repository: https://github.com/AyogoHealth/jest-ts-webcompat-resolver
- Issues: https://github.com/AyogoHealth/jest-ts-webcompat-resolver/issues
- npm.io page: https://npm.io/package/jest-ts-webcompat-resolver

## Recent versions

- 1.0.1 (latest) — 2025-04-23
- 1.0.0 — 2019-04-09

## README

Jest TypeScript Web-Compatible Resolver
=======================================

TypeScript allows importing other TypeScript files with a `.js` extension, for
compatibility with the ES6 modules loader specification. Unfortunately, Jest
gets confused by this and complains that it's not able to find the JavaScript
file.

This is a resolver that catches that error, and then tries to resolve it again
but with a `.ts` extension.


Installation & Set-Up
---------------------

Install this module into your project using npm:

```
npm install -D jest-ts-webcompat-resolver
```

Then add it to your Jest config file as the resolver:

```
"resolver": "jest-ts-webcompat-resolver"
```


Licence
-------

This project is licensed under the [MIT Licence][mit].

[mit]:
  https://github.com/AyogoHealth/jest-ts-webcompat-resolver/blob/master/LICENSE

---
_Source: https://npm.io/package/jest-ts-webcompat-resolver · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
