Skip to content

Commit

Permalink
feat(jest): support modulePathIgnorePatterns config.
Browse files Browse the repository at this point in the history
  • Loading branch information
jaywcjlove committed Jul 30, 2024
1 parent 6a5bb33 commit 17a7e1e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 1 addition & 1 deletion packages/jest/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import path, { dirname } from 'path';
import { runCLI } from '@jest/core';
import { Config } from '@jest/types';
import { type Config } from '@jest/types';
import { fileURLToPath } from 'url';
import createJestConfig from './jest.config.js';

Expand Down
9 changes: 9 additions & 0 deletions packages/jest/src/jest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,15 @@ export default async function jestConfig(resolve: Function, rootDir: string): Pr

if (overrides) {
const supportedKeys: (keyof Jest.Config)[] = [
/**
* https://jestjs.io/docs/configuration#modulepathignorepatterns-arraystring
* ```js
* const config = {
* modulePathIgnorePatterns: ['<rootDir>/build/'],
* };
* ```
*/
'modulePathIgnorePatterns',
/**
* https://jestjs.io/docs/configuration#setupfiles-array
*
Expand Down

0 comments on commit 17a7e1e

Please sign in to comment.