0.1.5 • Published 4 years ago

jest-module-name-mapper v0.1.5

Weekly downloads
1,985
License
MIT
Repository
github
Last release
4 years ago

Jest Module Name Mapper

License npm version Build Status codecov

Use this to avoid the declaration of the same module path aliases in tsconfig.json and jest.config.js. The package allows synchronizing Jest path aliases (moduleNameMapper) with your tsconfig.json configuration.

Installation

npm i jest-module-name-mapper -D

Usage

Set configuration in jest.config.js:

module.exports = {
  ...
  moduleNameMapper: require('jest-module-name-mapper')(),
};

If your tsconfig.json file is located in other directory then root, then you can set your own path to the file.

module.exports = {
  ...
  moduleNameMapper: require('jest-module-name-mapper')('/src/tsconfig.json'),
};

Author

0.1.5

4 years ago

0.1.4

4 years ago

0.1.3

4 years ago

0.1.2

5 years ago

0.1.1

5 years ago

0.1.0

5 years ago